Compare commits
18 Commits
| Author | SHA256 | Date | |
|---|---|---|---|
| 31d5c04ba6 | |||
| e46cf12053 | |||
| 0c1c20c6ed | |||
| 59fe590238 | |||
| 6e52b078f9 | |||
| e15417da74 | |||
| 49917940de | |||
| 64c4e1bfe9 | |||
| 8ac4089d94 | |||
| eb125f3e26 | |||
| 40545b9399 | |||
| f21c24a73a | |||
| eb9d208e96 | |||
| 020e5a0376 | |||
| 3f08e87a95 | |||
| ca8f51fa76 | |||
| 509b165231 | |||
| 489ccbc632 |
@@ -1,25 +0,0 @@
|
||||
From f6b4d0489040b1a4dcfb91bd9ed5860e72fbf085 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= <michal@cihar.com>
|
||||
Date: Tue, 2 Apr 2024 14:35:41 +0200
|
||||
Subject: [PATCH] tests: Adjust to changed aeidon behavior
|
||||
|
||||
Followup to https://github.com/otsaloma/gaupol/commit/92db8f1cf4b344b074ccb638f4220c8bef188350
|
||||
---
|
||||
tests/translate/convert/test_po2sub.py | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/tests/translate/convert/test_po2sub.py b/tests/translate/convert/test_po2sub.py
|
||||
index 8f031279..48c1015c 100644
|
||||
--- a/tests/translate/convert/test_po2sub.py
|
||||
+++ b/tests/translate/convert/test_po2sub.py
|
||||
@@ -56,6 +56,7 @@ Blah blah blah blah
|
||||
2
|
||||
00:00:24,600 --> 00:00:27,800
|
||||
Koei koei koei koei
|
||||
+
|
||||
"""
|
||||
subfile = self.merge2sub(subtemplate, posource)
|
||||
print(subexpected)
|
||||
--
|
||||
2.44.0
|
||||
|
||||
3
3.16.3.tar.gz
Normal file
3
3.16.3.tar.gz
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:659c527e9f10c45c8b08a18defd3346cb9f9c7b3680929e49428d13255e0b6e5
|
||||
size 1182562
|
||||
@@ -1,3 +1,4 @@
|
||||
<multibuild>
|
||||
<package>test</package>
|
||||
<package>man+doc</package>
|
||||
</multibuild>
|
||||
|
||||
@@ -1,16 +0,0 @@
|
||||
Description: Stop sphinx trying to download from network at build time
|
||||
Sphinx tries to download catalogues for intersphinx links -- suppress that
|
||||
here by removing the intersphinx extension.
|
||||
Author: Stuart Prescott <stuart@debian.org>
|
||||
Index: translate-toolkit-3.3.3/docs/conf.py
|
||||
===================================================================
|
||||
--- translate-toolkit-3.3.3.orig/docs/conf.py
|
||||
+++ translate-toolkit-3.3.3/docs/conf.py
|
||||
@@ -39,7 +39,6 @@ extensions = [
|
||||
"sphinx.ext.autodoc",
|
||||
"sphinx.ext.coverage",
|
||||
"sphinx.ext.extlinks",
|
||||
- "sphinx.ext.intersphinx",
|
||||
"sphinx.ext.todo",
|
||||
]
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:69e4c68f0e60a259b6176aa173bfeb0de6eba1c2adbfb0aa95a279ba4be26525
|
||||
size 1464295
|
||||
@@ -1,3 +1,102 @@
|
||||
-------------------------------------------------------------------
|
||||
Fri Nov 14 11:16:08 UTC 2025 - Luiz Fernando Ranghetti <elchevive@opensuse.org>
|
||||
|
||||
- Update various (build)requires versions
|
||||
- Correct the 'wcwidth' requirement (was set to another package 'cwcwidth')
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Nov 12 12:02:33 UTC 2025 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- update to 3.16.3:
|
||||
* Improvements in Android format
|
||||
* Python 3.14 compatibility
|
||||
- update to 3.16.2:
|
||||
* Improvements in PO and MO formats
|
||||
* Incomplete plurals handling
|
||||
* Big endian compatbility
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Oct 2 12:26:22 UTC 2025 - Markéta Machová <mmachova@suse.com>
|
||||
|
||||
- Update to 3.16.1
|
||||
* Improvements in Android and Markdown
|
||||
* Code and packaging cleanups
|
||||
* Improvements in CLDR tags handling
|
||||
* Improved convertor behavior with multiple files
|
||||
- Drop xliff-xsd-no-network.patch, fixed upstream
|
||||
- Swap to GitHub tarball, tests were dropped from the PyPI one
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Jun 19 16:22:38 UTC 2025 - Markéta Machová <mmachova@suse.com>
|
||||
|
||||
- Fix the doc build
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jun 18 11:35:40 UTC 2025 - Markéta Machová <mmachova@suse.com>
|
||||
|
||||
- Update to 3.15.5
|
||||
* Improvements to multiple formats.
|
||||
* Packaging now follows PEP 621.
|
||||
* Documentation improvements and cleanups.
|
||||
* Added support for Compose Multiplatform Resources
|
||||
* Added language definition for Toki Pona
|
||||
- Convert to libalternatives
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jan 15 14:52:14 UTC 2025 - Dominique Leuenberger <dimstar@opensuse.org>
|
||||
|
||||
- Only provide the 'translate-toolkit' symbol in the actual
|
||||
packages, not the doc/test flavored ones.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Jan 10 12:03:46 UTC 2025 - Markéta Machová <mmachova@suse.com>
|
||||
|
||||
- Split the documentation from the main package to avoid many new
|
||||
dependencies in Ring1
|
||||
* man pages are being made optional by this change
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Jan 6 12:55:03 UTC 2025 - Markéta Machová <mmachova@suse.com>
|
||||
|
||||
- Update to 3.14.5
|
||||
* Improvements to multiple formats.
|
||||
* Dropped support for Python 3.8.
|
||||
* Improved multistring implementation.
|
||||
* Python 3.13 compatiblity.
|
||||
- Drop merged py313.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Oct 30 17:12:33 UTC 2024 - Markéta Machová <mmachova@suse.com>
|
||||
|
||||
- Update to 3.13.3
|
||||
* Improved handling of MO files
|
||||
- Drop merged sphinx-intersphinx.patch
|
||||
- Add py313.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Jul 4 13:04:05 UTC 2024 - Markéta Machová <mmachova@suse.com>
|
||||
|
||||
- Update to 3.13.1
|
||||
* Added support for FormatJS
|
||||
* Several improvements to the PO, XML and Properties formats.
|
||||
* Updated language definitions to include CLDR aliases.
|
||||
* Dropped unmatained Mozilla l10n scripts.
|
||||
- Drop merged 0001-tests-Adjust-to-changed-aeidon-behavior.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sat Jun 29 19:59:19 UTC 2024 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- update to 3.13.1:
|
||||
* Compatibility with current pytest and setuptools.
|
||||
* Updated language definitions to include CLDR aliases.
|
||||
* Dropped unmatained Mozilla l10n scripts.
|
||||
* Updated aeidon compatibility
|
||||
* PO: Fixed newlines handling in notes
|
||||
* PO: Improved header handling
|
||||
* PO: Avoid adding duplicate context when merging duplicates
|
||||
- drop 0001-tests-Adjust-to-changed-aeidon-behavior.patch:
|
||||
(upstream)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Apr 8 13:28:24 UTC 2024 - Ana Guerrero <ana.guerrero@suse.com>
|
||||
|
||||
@@ -120,11 +219,11 @@ Tue Feb 1 20:38:55 UTC 2022 - Luiz Fernando Ranghetti <elchevive@opensuse.org>
|
||||
* Fixed adding strings to empty Ruby YAML file
|
||||
* Better handling of multiline stringtable translations in po2rc
|
||||
* Update CLDR data to 37.0.0
|
||||
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Dec 2 13:45:58 UTC 2021 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- skip fluent from testing, we don't depend on it anyway (it is optional)
|
||||
- skip fluent from testing, we don't depend on it anyway (it is optional)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Nov 29 20:54:40 UTC 2021 - Dirk Müller <dmueller@suse.com>
|
||||
@@ -176,8 +275,8 @@ Sun Dec 6 15:12:39 UTC 2020 - Benjamin Greiner <code@bnavigator.de>
|
||||
- refresh versionend_executables.patch
|
||||
- Fix name definition of -devel-doc package because of stricter
|
||||
python-rpm-macros %python_subpackages requirement
|
||||
- move html docs in common file tree to -doc package in order to
|
||||
avoid conflicts for multiple python flavor packages
|
||||
- move html docs in common file tree to -doc package in order to
|
||||
avoid conflicts for multiple python flavor packages
|
||||
gh#openSUSE/python-rpm-macros#66
|
||||
- replace my_install_alternatives by python_install_alternative
|
||||
* fix manpages alternatives install
|
||||
@@ -330,7 +429,7 @@ Mon Aug 28 19:39:16 UTC 2017 - elchevive@opensuse.org
|
||||
* po2txt no longer converts non-translatable strings.
|
||||
* Improvement for puncspace check.
|
||||
* Support for .xliff extension.
|
||||
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Jun 26 19:06:30 UTC 2017 - elchevive@opensuse.org
|
||||
|
||||
@@ -399,7 +498,7 @@ Thu Sep 1 11:26:19 UTC 2016 - elchevive@opensuse.org
|
||||
- Update to 1.99.5 (2.0.0 Beta 5)
|
||||
* Minor fixes
|
||||
- require lxml 3.5.0 or newer
|
||||
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jul 27 09:53:37 UTC 2016 - buschmann23@opensuse.org
|
||||
|
||||
@@ -578,7 +677,7 @@ Format support:
|
||||
- Improved handling of trailing spaces in Mozilla DTD files
|
||||
- Removed unused support for _old_ KDE plurals in pocount
|
||||
|
||||
...and several small bugfixes
|
||||
...and several small bugfixes
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Dec 27 16:24:00 GMT 2010 - elchevive@opensuse.org
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package translate-toolkit
|
||||
#
|
||||
# Copyright (c) 2023 SUSE LLC
|
||||
# Copyright (c) 2025 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@@ -20,15 +20,24 @@
|
||||
%if "%{flavor}" == "test"
|
||||
%define psuffix -test
|
||||
%bcond_without test
|
||||
%else
|
||||
%bcond_with doc
|
||||
%endif
|
||||
%if "%{flavor}" == "man+doc"
|
||||
%define psuffix -man
|
||||
%bcond_with test
|
||||
%bcond_without doc
|
||||
%endif
|
||||
%if "%{flavor}" == ""
|
||||
%define psuffix %{nil}
|
||||
%bcond_with test
|
||||
%bcond_with doc
|
||||
%endif
|
||||
%define modname translate-toolkit
|
||||
%define modname translate_toolkit
|
||||
%define pkgname translate-toolkit
|
||||
%bcond_without libalternatives
|
||||
|
||||
%define binaries_and_manpages %{shrink:\
|
||||
poclean pocompile poconflicts podebug pofilter pogrep pomerge porestructure posegment poswap poterminology \
|
||||
build_firefox.sh pretranslate \
|
||||
pretranslate poclean pocompile poconflicts podebug pofilter pogrep pomerge porestructure posegment poswap poterminology \
|
||||
android2po csv2po csv2tbx dtd2po flatxml2po html2po ical2po idml2po ini2po json2po \
|
||||
moz2po mozfunny2prop mozlang2po odf2xliff oo2po oo2xliff php2po phppo2pypo \
|
||||
po2csv po2dtd po2flatxml po2html po2ical po2idml po2ini po2json po2moz po2mozlang po2oo \
|
||||
@@ -37,75 +46,70 @@
|
||||
tbx2po tiki2po ts2po txt2po web2py2po xliff2odf xliff2oo xliff2po yaml2po}
|
||||
%define binaries %{shrink: %binaries_and_manpages\
|
||||
pocommentclean pocompendium pocount pomigrate2 popuretext poreencode posplit prop2mozfunny \
|
||||
build_tmdb buildxpi.py get_moz_enUS.py pydiff tmserver junitmsgfmt md2po po2md}
|
||||
build_tmdb pydiff tmserver junitmsgfmt md2po po2md}
|
||||
%define manpages translatetoolkit %binaries_and_manpages
|
||||
|
||||
Name: translate-toolkit%{psuffix}
|
||||
Version: 3.12.1
|
||||
Version: 3.16.3
|
||||
Release: 0
|
||||
Summary: Tools and API to assist with translation and software localization
|
||||
License: GPL-2.0-or-later
|
||||
URL: https://toolkit.translatehouse.org/
|
||||
Source: https://files.pythonhosted.org/packages/source/t/%{modname}/%{modname}-%{version}.tar.gz
|
||||
Patch0: xliff-xsd-no-network.patch
|
||||
Patch1: sphinx-intersphinx.patch
|
||||
# PATCH-FIX-UPSTREAM
|
||||
Patch2: 0001-tests-Adjust-to-changed-aeidon-behavior.patch
|
||||
BuildRequires: %{python_module Levenshtein >= 0.12}
|
||||
BuildRequires: %{python_module Sphinx}
|
||||
BuildRequires: %{python_module sphinx-bootstrap-theme}
|
||||
BuildRequires: %{python_module base >= 3.7}
|
||||
BuildRequires: %{python_module beautifulsoup4 >= 4.3}
|
||||
# extra modules here are needed for manpages
|
||||
BuildRequires: %{python_module cheroot >= 9}
|
||||
Source: https://github.com/translate/translate/archive/refs/tags/%{version}.tar.gz
|
||||
BuildRequires: %{python_module base >= 3.10}
|
||||
BuildRequires: %{python_module cheroot >= 10}
|
||||
BuildRequires: %{python_module wcwidth >= 0.2.14}
|
||||
BuildRequires: %{python_module iniparse >= 0.5}
|
||||
BuildRequires: %{python_module lxml >= 4.6.3}
|
||||
BuildRequires: %{python_module phply >= 1.2.5}
|
||||
BuildRequires: %{python_module ruamel.yaml >= 0.17.21}
|
||||
BuildRequires: %{python_module lxml >= 5.2.0}
|
||||
BuildRequires: %{python_module matplotlib}
|
||||
BuildRequires: %{python_module pip}
|
||||
BuildRequires: %{python_module pyparsing}
|
||||
BuildRequires: %{python_module setuptools >= 42}
|
||||
BuildRequires: %{python_module setuptools_scm >= 6.2}
|
||||
BuildRequires: %{python_module vobject >= 0.9.6.1}
|
||||
BuildRequires: %{python_module phply >= 1.2.6}
|
||||
BuildRequires: %{python_module ruamel.yaml >= 0.18.0}
|
||||
BuildRequires: %{python_module setuptools >= 78.0.2}
|
||||
BuildRequires: %{python_module vobject >= 0.9.9}
|
||||
BuildRequires: %{python_module wheel}
|
||||
BuildRequires: alts
|
||||
BuildRequires: dos2unix
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: gettext-runtime
|
||||
BuildRequires: git-core
|
||||
BuildRequires: iso-codes
|
||||
BuildRequires: python-rpm-macros
|
||||
Requires: alts
|
||||
Requires: gettext-runtime
|
||||
Requires: python
|
||||
Requires: python-lxml >= 4.6.3
|
||||
Requires(post): update-alternatives
|
||||
Requires(postun): update-alternatives
|
||||
Requires: python-wcwidth >= 0.2.14
|
||||
Requires: python-lxml >= 5.2.0
|
||||
# The following are for the full experience of translate-toolkit
|
||||
Recommends: %{name}-doc
|
||||
Recommends: %{name}-man
|
||||
Recommends: gaupol
|
||||
Recommends: iso-codes
|
||||
Recommends: python-Levenshtein >= 0.12
|
||||
Recommends: python-aeidon >= 1.13
|
||||
Recommends: python-beautifulsoup4 >= 4.3
|
||||
Recommends: python-charset-normalizer >= 3.3.2
|
||||
Recommends: python-Levenshtein >= 0.21.0
|
||||
Recommends: python-aeidon >= 1.14.1
|
||||
Recommends: python-beautifulsoup4 >= 4.13.0
|
||||
Recommends: python-charset-normalizer >= 3.4.0
|
||||
Recommends: python-cheroot >= 10
|
||||
Recommends: python-iniparse >= 0.5
|
||||
Recommends: python-mistletoe >= 1.2.1
|
||||
Recommends: python-mistletoe >= 1.4.0
|
||||
Recommends: python-phply >= 1.2.6
|
||||
Recommends: python-pyenchant >= 3.2.2
|
||||
Recommends: python-pyparsing >= 3.1.1
|
||||
Recommends: python-ruamel.yaml >= 0.18.5
|
||||
Recommends: python-vobject >= 0.9.6.1
|
||||
%if "%{python_flavor}" == "python3" || "%{?python_provides}" == "python3"
|
||||
Recommends: python-pyparsing >= 3.2.0
|
||||
Recommends: python-ruamel.yaml >= 0.18.0
|
||||
Recommends: python-vobject >= 0.9.9
|
||||
%if %{without test} && %{without doc} && ("%{python_flavor}" == "python3" || "%{?python_provides}" == "python3")
|
||||
Provides: translate-toolkit = %{version}-%{release}
|
||||
Obsoletes: translate-toolkit < %{version}-%{release}
|
||||
%endif
|
||||
BuildArch: noarch
|
||||
%if %{with test}
|
||||
BuildRequires: %{python_module aeidon >= 1.13}
|
||||
BuildRequires: %{python_module chardet}
|
||||
BuildRequires: %{python_module mistletoe >= 1.2.1}
|
||||
BuildRequires: %{python_module Levenshtein >= 0.21.0}
|
||||
BuildRequires: %{python_module aeidon >= 1.14.1}
|
||||
BuildRequires: %{python_module beautifulsoup4 >= 4.13.0}
|
||||
BuildRequires: %{python_module charset-normalizer >= 3.3.2}
|
||||
BuildRequires: %{python_module mistletoe >= 1.4.0}
|
||||
BuildRequires: %{python_module pyenchant >= 3.2.2}
|
||||
BuildRequires: %{python_module pyparsing >= 3.1.1}
|
||||
BuildRequires: %{python_module pyparsing >= 3.2.0}
|
||||
BuildRequires: %{python_module pytest}
|
||||
BuildRequires: %{python_module pytest-xdist}
|
||||
BuildRequires: %{python_module translate-toolkit = %{version}}
|
||||
@@ -113,8 +117,43 @@ BuildRequires: %{python_module xml}
|
||||
BuildRequires: %{python_module syrupy}
|
||||
BuildRequires: gaupol
|
||||
%endif
|
||||
%if %{with doc}
|
||||
BuildRequires: %{python_module Sphinx}
|
||||
BuildRequires: %{python_module furo}
|
||||
BuildRequires: %{python_module sphinxcontrib-copybutton}
|
||||
BuildRequires: %{python_module sphinxext-opengraph}
|
||||
BuildRequires: %{python_module translate-toolkit = %{version}}
|
||||
Requires: %{pkgname} = %{version}
|
||||
Supplements: %{pkgname} = %{version}
|
||||
%endif
|
||||
%python_subpackages
|
||||
|
||||
%if "%{flavor}" == "man+doc"
|
||||
%description
|
||||
The %{pkgname}-man package contains manual pages for %{pkgname}.
|
||||
|
||||
%package -n %{pkgname}-doc
|
||||
Summary: Tools and API to assist with translation and software localization -- HTML docs
|
||||
Requires: %{pkgname} = %{version}
|
||||
BuildArch: noarch
|
||||
|
||||
%description -n %{pkgname}-doc
|
||||
The %{pkgname}-doc package contains Translate Toolkit documentation in HTML format.
|
||||
|
||||
%package -n %{pkgname}-devel-doc
|
||||
Summary: Tools and API to assist with translation and software localization -- API docs
|
||||
Requires: %{pkgname} = %{version}
|
||||
Requires: %{pkgname}-doc = %{version}
|
||||
Provides: %{pkgname}-devel = %{version}
|
||||
Obsoletes: %{pkgname}-devel < %{version}
|
||||
BuildArch: noarch
|
||||
|
||||
%description -n %{pkgname}-devel-doc
|
||||
The %{pkgname}-devel-doc package contains Translate Toolkit API documentation for developers wishing to build new tools for the
|
||||
toolkit or to use the libraries in other localization tools.
|
||||
|
||||
%else
|
||||
|
||||
%description
|
||||
The Translate Toolkit is a set of software and documentation designed to help
|
||||
make the lives of localizers both more productive and less frustrating.
|
||||
@@ -133,33 +172,12 @@ these formats.
|
||||
|
||||
Also part of the Toolkit are Python programs to create word counts, merge
|
||||
translations and perform various checks on translation files.
|
||||
|
||||
%package -n %{name}-doc
|
||||
Summary: Tools and API to assist with translation and software localization -- HTML docs
|
||||
Requires: %{name} = %{version}
|
||||
BuildArch: noarch
|
||||
|
||||
%description -n %{name}-doc
|
||||
The %{name}-doc package contains Translate Toolkit documentation in HTML format.
|
||||
|
||||
%package -n %{name}-devel-doc
|
||||
Summary: Tools and API to assist with translation and software localization -- API docs
|
||||
Requires: %{name} = %{version}
|
||||
Requires: %{name}-doc = %{version}
|
||||
Provides: %{name}-devel = %{version}
|
||||
Obsoletes: %{name}-devel < %{version}
|
||||
BuildArch: noarch
|
||||
|
||||
%description -n %{name}-devel-doc
|
||||
The %{name}-devel-doc package contains Translate Toolkit API documentation for developers wishing to build new tools for the
|
||||
toolkit or to use the libraries in other localization tools.
|
||||
%endif
|
||||
|
||||
%prep
|
||||
%setup -q -n %{modname}-%{version}
|
||||
%setup -q -n translate-%{version}
|
||||
%autopatch -p1
|
||||
|
||||
sed -i 296"s|'share'|'translate/share'|" setup.py
|
||||
|
||||
#Fix for shebang errors:
|
||||
for lib in translate/{*.py,*/*.py,*/*/*.py}; do
|
||||
sed -i '\|%{_bindir}/env |d' $lib
|
||||
@@ -169,25 +187,40 @@ find . -name jquery.js -exec dos2unix '{}' \;
|
||||
|
||||
%build
|
||||
%if !%{with test}
|
||||
%if !%{with doc}
|
||||
%pyproject_wheel
|
||||
|
||||
%else
|
||||
|
||||
# build docs
|
||||
pushd docs
|
||||
# Can't use parallel build here!
|
||||
%make_build -j1 html man
|
||||
%make_build SPHINXBUILD=sphinx-build -j1 man html
|
||||
#no hidden files
|
||||
find _build -name '.?*' -delete
|
||||
popd
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%install
|
||||
%if !%{with test}
|
||||
%if !%{with doc}
|
||||
%pyproject_install
|
||||
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
||||
|
||||
# Prepare alternatives for binaries
|
||||
for binary in %{binaries} ; do
|
||||
%python_clone -a %{buildroot}%{_bindir}/$binary
|
||||
done
|
||||
|
||||
%else
|
||||
|
||||
# create manpages
|
||||
mkdir -p %{buildroot}%{_mandir}/man1
|
||||
for program in %{buildroot}%{_bindir}/*; do
|
||||
MPAGE="%{buildroot}%{_mandir}/man1/$(basename $program).1"
|
||||
LC_ALL=C PYTHONPATH=. $program --manpage > "$MPAGE" || rm -f "$MPAGE"
|
||||
for program in %{binaries}; do
|
||||
MPAGE="%{buildroot}%{_mandir}/man1/$program.1"
|
||||
LC_ALL=C PYTHONPATH=. %{_bindir}/$program --manpage > "$MPAGE" || rm -f "$MPAGE"
|
||||
done
|
||||
install -m 644 docs/_build/man/* %{buildroot}%{_mandir}/man1/
|
||||
|
||||
@@ -200,16 +233,13 @@ rm -rf %{buildroot}home/abuild/.local/lib/python%{$python_version}/site-packages
|
||||
|
||||
# create symlinks for man pages
|
||||
%fdupes -s %{buildroot}%{_mandir}
|
||||
# create hardlinks for the rest
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
||||
|
||||
# Prepare alternatives
|
||||
# Prepare alternatives for manpages
|
||||
for mpage in %{manpages} ; do
|
||||
%python_clone -a %{buildroot}%{_mandir}/man1/$mpage.1
|
||||
done
|
||||
for binary in %{binaries} ; do
|
||||
%python_clone -a %{buildroot}%{_bindir}/$binary
|
||||
done
|
||||
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%check
|
||||
@@ -218,30 +248,44 @@ rm -v tests/translate/storage/test_fluent.py
|
||||
%pytest
|
||||
%endif
|
||||
|
||||
%post
|
||||
%python_install_alternative %{lua: for m in string.gmatch(rpm.expand("%manpages"),"%S+") do print(m .. ".1 ") end} %binaries
|
||||
|
||||
%postun
|
||||
%python_uninstall_alternative translatetoolkit.1%{?ext_man}
|
||||
|
||||
%if !%{with test}
|
||||
%if !%{with doc}
|
||||
|
||||
%pre
|
||||
%python_libalternatives_reset_alternative pretranslate
|
||||
|
||||
%files %{python_files}
|
||||
%license COPYING
|
||||
%doc README.rst
|
||||
%{lua: for b in string.gmatch(rpm.expand("%binaries"),"%S+") do print(rpm.expand("%python_alternative %{_bindir}/" .. b) .. "\n") end}
|
||||
%{lua: for m in string.gmatch(rpm.expand("%manpages"),"%S+") do print(rpm.expand("%python_alternative %{_mandir}/man1/" .. m .. ".1") .. "\n") end}
|
||||
%{python_sitelib}/translate
|
||||
%{python_sitelib}/translate_toolkit-%{version}.dist-info
|
||||
|
||||
%files -n %{name}-doc
|
||||
%else
|
||||
|
||||
%pre
|
||||
%python_libalternatives_reset_alternative translatetoolkit.1%{?ext_man}
|
||||
|
||||
%files %{python_files}
|
||||
%license COPYING
|
||||
%doc README.rst
|
||||
%{lua: for m in string.gmatch(rpm.expand("%manpages"),"%S+") do print(rpm.expand("%python_alternative %{_mandir}/man1/" .. m .. ".1") .. "\n") end}
|
||||
# needed because we are building manpages separately
|
||||
%if %{with libalternatives}
|
||||
%{lua: for m in string.gmatch(rpm.expand("%manpages"),"%S+") do print(rpm.expand("%dir %{_datadir}/libalternatives/" .. m .. "") .. "\n") end}
|
||||
%{lua: for m in string.gmatch(rpm.expand("%manpages"),"%S+") do print(rpm.expand("%{_datadir}/libalternatives/" .. m .. "/*%{python_version_nodots}.conf") .. "\n") end}
|
||||
%endif
|
||||
|
||||
%files -n %{pkgname}-doc
|
||||
%dir %{_defaultdocdir}/%{modname}
|
||||
%doc %{_defaultdocdir}/%{modname}/html/
|
||||
%exclude %{_defaultdocdir}/%{modname}/html/api
|
||||
%exclude %{_defaultdocdir}/%{modname}/html/_sources
|
||||
|
||||
%files -n %{name}-devel-doc
|
||||
%files -n %{pkgname}-devel-doc
|
||||
%doc %{_defaultdocdir}/%{modname}/html/api
|
||||
%doc %{_defaultdocdir}/%{modname}/html/_sources
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
|
||||
@@ -1,305 +0,0 @@
|
||||
Description: Provide local version of XSD to prevent network access
|
||||
The xliff xsd imports xml.xsd which will result in network access. Include
|
||||
a local copy of this resource instead.
|
||||
Author: Stuart Prescott <stuart@debian.org>
|
||||
--- a/tests/xliff_conformance/xliff-core-1.1.xsd
|
||||
+++ b/tests/xliff_conformance/xliff-core-1.1.xsd
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<xsd:schema targetNamespace="urn:oasis:names:tc:xliff:document:1.1" xmlns:xyz="urn:appInfo:Items" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xlf="urn:oasis:names:tc:xliff:document:1.1" elementFormDefault="qualified" xml:lang="en">
|
||||
|
||||
<!-- Import for xml:lang and xml:space -->
|
||||
|
||||
- <xsd:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="http://www.w3.org/2001/xml.xsd"/>
|
||||
|
||||
+ <xsd:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="xml.xsd"/>
|
||||
|
||||
<!-- Attributes Lists -->
|
||||
|
||||
<xsd:simpleType name="XTend">
|
||||
|
||||
<xsd:restriction base="xsd:string">
|
||||
|
||||
--- /dev/null
|
||||
+++ b/tests/xliff_conformance/xml.xsd
|
||||
@@ -0,0 +1,287 @@
|
||||
+<?xml version='1.0'?>
|
||||
+<?xml-stylesheet href="../2008/09/xsd.xsl" type="text/xsl"?>
|
||||
+<xs:schema targetNamespace="http://www.w3.org/XML/1998/namespace"
|
||||
+ xmlns:xs="http://www.w3.org/2001/XMLSchema"
|
||||
+ xmlns ="http://www.w3.org/1999/xhtml"
|
||||
+ xml:lang="en">
|
||||
+
|
||||
+ <xs:annotation>
|
||||
+ <xs:documentation>
|
||||
+ <div>
|
||||
+ <h1>About the XML namespace</h1>
|
||||
+
|
||||
+ <div class="bodytext">
|
||||
+ <p>
|
||||
+ This schema document describes the XML namespace, in a form
|
||||
+ suitable for import by other schema documents.
|
||||
+ </p>
|
||||
+ <p>
|
||||
+ See <a href="http://www.w3.org/XML/1998/namespace.html">
|
||||
+ http://www.w3.org/XML/1998/namespace.html</a> and
|
||||
+ <a href="http://www.w3.org/TR/REC-xml">
|
||||
+ http://www.w3.org/TR/REC-xml</a> for information
|
||||
+ about this namespace.
|
||||
+ </p>
|
||||
+ <p>
|
||||
+ Note that local names in this namespace are intended to be
|
||||
+ defined only by the World Wide Web Consortium or its subgroups.
|
||||
+ The names currently defined in this namespace are listed below.
|
||||
+ They should not be used with conflicting semantics by any Working
|
||||
+ Group, specification, or document instance.
|
||||
+ </p>
|
||||
+ <p>
|
||||
+ See further below in this document for more information about <a
|
||||
+ href="#usage">how to refer to this schema document from your own
|
||||
+ XSD schema documents</a> and about <a href="#nsversioning">the
|
||||
+ namespace-versioning policy governing this schema document</a>.
|
||||
+ </p>
|
||||
+ </div>
|
||||
+ </div>
|
||||
+ </xs:documentation>
|
||||
+ </xs:annotation>
|
||||
+
|
||||
+ <xs:attribute name="lang">
|
||||
+ <xs:annotation>
|
||||
+ <xs:documentation>
|
||||
+ <div>
|
||||
+
|
||||
+ <h3>lang (as an attribute name)</h3>
|
||||
+ <p>
|
||||
+ denotes an attribute whose value
|
||||
+ is a language code for the natural language of the content of
|
||||
+ any element; its value is inherited. This name is reserved
|
||||
+ by virtue of its definition in the XML specification.</p>
|
||||
+
|
||||
+ </div>
|
||||
+ <div>
|
||||
+ <h4>Notes</h4>
|
||||
+ <p>
|
||||
+ Attempting to install the relevant ISO 2- and 3-letter
|
||||
+ codes as the enumerated possible values is probably never
|
||||
+ going to be a realistic possibility.
|
||||
+ </p>
|
||||
+ <p>
|
||||
+ See BCP 47 at <a href="http://www.rfc-editor.org/rfc/bcp/bcp47.txt">
|
||||
+ http://www.rfc-editor.org/rfc/bcp/bcp47.txt</a>
|
||||
+ and the IANA language subtag registry at
|
||||
+ <a href="http://www.iana.org/assignments/language-subtag-registry">
|
||||
+ http://www.iana.org/assignments/language-subtag-registry</a>
|
||||
+ for further information.
|
||||
+ </p>
|
||||
+ <p>
|
||||
+ The union allows for the 'un-declaration' of xml:lang with
|
||||
+ the empty string.
|
||||
+ </p>
|
||||
+ </div>
|
||||
+ </xs:documentation>
|
||||
+ </xs:annotation>
|
||||
+ <xs:simpleType>
|
||||
+ <xs:union memberTypes="xs:language">
|
||||
+ <xs:simpleType>
|
||||
+ <xs:restriction base="xs:string">
|
||||
+ <xs:enumeration value=""/>
|
||||
+ </xs:restriction>
|
||||
+ </xs:simpleType>
|
||||
+ </xs:union>
|
||||
+ </xs:simpleType>
|
||||
+ </xs:attribute>
|
||||
+
|
||||
+ <xs:attribute name="space">
|
||||
+ <xs:annotation>
|
||||
+ <xs:documentation>
|
||||
+ <div>
|
||||
+
|
||||
+ <h3>space (as an attribute name)</h3>
|
||||
+ <p>
|
||||
+ denotes an attribute whose
|
||||
+ value is a keyword indicating what whitespace processing
|
||||
+ discipline is intended for the content of the element; its
|
||||
+ value is inherited. This name is reserved by virtue of its
|
||||
+ definition in the XML specification.</p>
|
||||
+
|
||||
+ </div>
|
||||
+ </xs:documentation>
|
||||
+ </xs:annotation>
|
||||
+ <xs:simpleType>
|
||||
+ <xs:restriction base="xs:NCName">
|
||||
+ <xs:enumeration value="default"/>
|
||||
+ <xs:enumeration value="preserve"/>
|
||||
+ </xs:restriction>
|
||||
+ </xs:simpleType>
|
||||
+ </xs:attribute>
|
||||
+
|
||||
+ <xs:attribute name="base" type="xs:anyURI"> <xs:annotation>
|
||||
+ <xs:documentation>
|
||||
+ <div>
|
||||
+
|
||||
+ <h3>base (as an attribute name)</h3>
|
||||
+ <p>
|
||||
+ denotes an attribute whose value
|
||||
+ provides a URI to be used as the base for interpreting any
|
||||
+ relative URIs in the scope of the element on which it
|
||||
+ appears; its value is inherited. This name is reserved
|
||||
+ by virtue of its definition in the XML Base specification.</p>
|
||||
+
|
||||
+ <p>
|
||||
+ See <a
|
||||
+ href="http://www.w3.org/TR/xmlbase/">http://www.w3.org/TR/xmlbase/</a>
|
||||
+ for information about this attribute.
|
||||
+ </p>
|
||||
+ </div>
|
||||
+ </xs:documentation>
|
||||
+ </xs:annotation>
|
||||
+ </xs:attribute>
|
||||
+
|
||||
+ <xs:attribute name="id" type="xs:ID">
|
||||
+ <xs:annotation>
|
||||
+ <xs:documentation>
|
||||
+ <div>
|
||||
+
|
||||
+ <h3>id (as an attribute name)</h3>
|
||||
+ <p>
|
||||
+ denotes an attribute whose value
|
||||
+ should be interpreted as if declared to be of type ID.
|
||||
+ This name is reserved by virtue of its definition in the
|
||||
+ xml:id specification.</p>
|
||||
+
|
||||
+ <p>
|
||||
+ See <a
|
||||
+ href="http://www.w3.org/TR/xml-id/">http://www.w3.org/TR/xml-id/</a>
|
||||
+ for information about this attribute.
|
||||
+ </p>
|
||||
+ </div>
|
||||
+ </xs:documentation>
|
||||
+ </xs:annotation>
|
||||
+ </xs:attribute>
|
||||
+
|
||||
+ <xs:attributeGroup name="specialAttrs">
|
||||
+ <xs:attribute ref="xml:base"/>
|
||||
+ <xs:attribute ref="xml:lang"/>
|
||||
+ <xs:attribute ref="xml:space"/>
|
||||
+ <xs:attribute ref="xml:id"/>
|
||||
+ </xs:attributeGroup>
|
||||
+
|
||||
+ <xs:annotation>
|
||||
+ <xs:documentation>
|
||||
+ <div>
|
||||
+
|
||||
+ <h3>Father (in any context at all)</h3>
|
||||
+
|
||||
+ <div class="bodytext">
|
||||
+ <p>
|
||||
+ denotes Jon Bosak, the chair of
|
||||
+ the original XML Working Group. This name is reserved by
|
||||
+ the following decision of the W3C XML Plenary and
|
||||
+ XML Coordination groups:
|
||||
+ </p>
|
||||
+ <blockquote>
|
||||
+ <p>
|
||||
+ In appreciation for his vision, leadership and
|
||||
+ dedication the W3C XML Plenary on this 10th day of
|
||||
+ February, 2000, reserves for Jon Bosak in perpetuity
|
||||
+ the XML name "xml:Father".
|
||||
+ </p>
|
||||
+ </blockquote>
|
||||
+ </div>
|
||||
+ </div>
|
||||
+ </xs:documentation>
|
||||
+ </xs:annotation>
|
||||
+
|
||||
+ <xs:annotation>
|
||||
+ <xs:documentation>
|
||||
+ <div xml:id="usage" id="usage">
|
||||
+ <h2><a name="usage">About this schema document</a></h2>
|
||||
+
|
||||
+ <div class="bodytext">
|
||||
+ <p>
|
||||
+ This schema defines attributes and an attribute group suitable
|
||||
+ for use by schemas wishing to allow <code>xml:base</code>,
|
||||
+ <code>xml:lang</code>, <code>xml:space</code> or
|
||||
+ <code>xml:id</code> attributes on elements they define.
|
||||
+ </p>
|
||||
+ <p>
|
||||
+ To enable this, such a schema must import this schema for
|
||||
+ the XML namespace, e.g. as follows:
|
||||
+ </p>
|
||||
+ <pre>
|
||||
+ <schema . . .>
|
||||
+ . . .
|
||||
+ <import namespace="http://www.w3.org/XML/1998/namespace"
|
||||
+ schemaLocation="http://www.w3.org/2001/xml.xsd"/>
|
||||
+ </pre>
|
||||
+ <p>
|
||||
+ or
|
||||
+ </p>
|
||||
+ <pre>
|
||||
+ <import namespace="http://www.w3.org/XML/1998/namespace"
|
||||
+ schemaLocation="http://www.w3.org/2009/01/xml.xsd"/>
|
||||
+ </pre>
|
||||
+ <p>
|
||||
+ Subsequently, qualified reference to any of the attributes or the
|
||||
+ group defined below will have the desired effect, e.g.
|
||||
+ </p>
|
||||
+ <pre>
|
||||
+ <type . . .>
|
||||
+ . . .
|
||||
+ <attributeGroup ref="xml:specialAttrs"/>
|
||||
+ </pre>
|
||||
+ <p>
|
||||
+ will define a type which will schema-validate an instance element
|
||||
+ with any of those attributes.
|
||||
+ </p>
|
||||
+ </div>
|
||||
+ </div>
|
||||
+ </xs:documentation>
|
||||
+ </xs:annotation>
|
||||
+
|
||||
+ <xs:annotation>
|
||||
+ <xs:documentation>
|
||||
+ <div id="nsversioning" xml:id="nsversioning">
|
||||
+ <h2><a name="nsversioning">Versioning policy for this schema document</a></h2>
|
||||
+ <div class="bodytext">
|
||||
+ <p>
|
||||
+ In keeping with the XML Schema WG's standard versioning
|
||||
+ policy, this schema document will persist at
|
||||
+ <a href="http://www.w3.org/2009/01/xml.xsd">
|
||||
+ http://www.w3.org/2009/01/xml.xsd</a>.
|
||||
+ </p>
|
||||
+ <p>
|
||||
+ At the date of issue it can also be found at
|
||||
+ <a href="http://www.w3.org/2001/xml.xsd">
|
||||
+ http://www.w3.org/2001/xml.xsd</a>.
|
||||
+ </p>
|
||||
+ <p>
|
||||
+ The schema document at that URI may however change in the future,
|
||||
+ in order to remain compatible with the latest version of XML
|
||||
+ Schema itself, or with the XML namespace itself. In other words,
|
||||
+ if the XML Schema or XML namespaces change, the version of this
|
||||
+ document at <a href="http://www.w3.org/2001/xml.xsd">
|
||||
+ http://www.w3.org/2001/xml.xsd
|
||||
+ </a>
|
||||
+ will change accordingly; the version at
|
||||
+ <a href="http://www.w3.org/2009/01/xml.xsd">
|
||||
+ http://www.w3.org/2009/01/xml.xsd
|
||||
+ </a>
|
||||
+ will not change.
|
||||
+ </p>
|
||||
+ <p>
|
||||
+ Previous dated (and unchanging) versions of this schema
|
||||
+ document are at:
|
||||
+ </p>
|
||||
+ <ul>
|
||||
+ <li><a href="http://www.w3.org/2009/01/xml.xsd">
|
||||
+ http://www.w3.org/2009/01/xml.xsd</a></li>
|
||||
+ <li><a href="http://www.w3.org/2007/08/xml.xsd">
|
||||
+ http://www.w3.org/2007/08/xml.xsd</a></li>
|
||||
+ <li><a href="http://www.w3.org/2004/10/xml.xsd">
|
||||
+ http://www.w3.org/2004/10/xml.xsd</a></li>
|
||||
+ <li><a href="http://www.w3.org/2001/03/xml.xsd">
|
||||
+ http://www.w3.org/2001/03/xml.xsd</a></li>
|
||||
Reference in New Issue
Block a user