15
0
forked from pool/python-rjsmin
Files
python-rjsmin/python-rjsmin.spec
Markéta Machová 1ef6a89350 Accepting request 970122 from home:pgajdos:python
- version update to 1.2.0
 *) Improve regex detection. Fixes #17, #23
 *) Add aarch64 wheels (issue #24, #25, contributed by odidev)
 *) Add tests to source distribution (issue #20, contributed by dvzrv)
 *) bytearray input now produces bytearray output
 *) Update python support: 2.7, 3.6+
 *) Emit the correct env var name in the warning message if the compilation of
    the C implementation fails.
- modified patches
  % reproducible.patch (refreshed)

OBS-URL: https://build.opensuse.org/request/show/970122
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-rjsmin?expand=0&rev=16
2022-04-14 16:39:21 +00:00

70 lines
2.0 KiB
RPMSpec

#
# spec file
#
# Copyright (c) 2022 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define mod_name rjsmin
%bcond_without python2
Name: python-%{mod_name}
Version: 1.2.0
Release: 0
Summary: A JavaScript minifier written in Python
License: Apache-2.0
URL: http://opensource.perlig.de/rjsmin/
Source: https://github.com/ndparker/rjsmin/archive/refs/tags/%{version}.tar.gz#/rjsmin-%{version}.tar.gz
# PATCH-FIX-OPENSUSE -- build without profiling
Patch0: reproducible.patch
BuildRequires: %{python_module devel}
BuildRequires: %{python_module pytest}
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Obsoletes: %{name}-doc
%if %{with python2}
BuildRequires: python-mock
%endif
%python_subpackages
%description
rJSmin is a Javascript minifier written in Python.
The minifier is based on the semantics of jsmin.c by Douglas Crockford.
The module is a re-implementation targeting speed, so it can be used
at runtime (rather than during a preprocessing step).
%prep
%setup -q -n %{mod_name}-%{version}
%autopatch -p1
%build
%python_build
%install
%python_install
rm -rf %{buildroot}%{_datadir}/doc/rjsmin
%check
%pytest_arch
%files %{python_files}
%license LICENSE
%doc README.md docs/CHANGES
%{python_sitearch}/*
%changelog