2016-01-12 15:08:31 +00:00
|
|
|
#
|
2016-04-01 04:37:31 +00:00
|
|
|
# spec file for package python-libsass
|
2016-01-12 15:08:31 +00:00
|
|
|
#
|
2020-04-15 13:01:39 +00:00
|
|
|
# Copyright (c) 2020 SUSE LLC
|
2016-01-12 15:08:31 +00:00
|
|
|
#
|
|
|
|
|
# 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.
|
|
|
|
|
|
2019-04-05 11:42:33 +00:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2016-01-12 15:08:31 +00:00
|
|
|
#
|
|
|
|
|
|
2016-04-01 04:37:31 +00:00
|
|
|
|
2020-04-15 13:01:39 +00:00
|
|
|
%define _name libsass-python
|
2017-05-16 15:14:02 +00:00
|
|
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
2016-01-12 15:08:31 +00:00
|
|
|
Name: python-libsass
|
2020-04-15 13:01:39 +00:00
|
|
|
Version: 0.19.4
|
2016-01-12 15:08:31 +00:00
|
|
|
Release: 0
|
|
|
|
|
Summary: Python binding for libsass
|
2016-04-01 04:37:31 +00:00
|
|
|
License: MIT
|
2016-01-12 15:08:31 +00:00
|
|
|
Group: Development/Languages/Python
|
2019-04-05 11:42:33 +00:00
|
|
|
URL: https://github.com/sass/libsass-python
|
2020-04-15 13:01:39 +00:00
|
|
|
Source: https://github.com/sass/libsass-python/archive/%{version}.tar.gz
|
2017-05-16 15:14:02 +00:00
|
|
|
BuildRequires: %{python_module Cython}
|
|
|
|
|
BuildRequires: %{python_module devel}
|
|
|
|
|
BuildRequires: %{python_module setuptools}
|
2019-04-05 11:42:33 +00:00
|
|
|
BuildRequires: %{python_module six}
|
2016-04-01 04:37:31 +00:00
|
|
|
BuildRequires: fdupes
|
2016-01-12 15:08:31 +00:00
|
|
|
BuildRequires: gcc-c++
|
2019-04-05 11:42:33 +00:00
|
|
|
BuildRequires: libsass-devel
|
2017-05-16 15:14:02 +00:00
|
|
|
BuildRequires: python-rpm-macros
|
2016-01-12 15:08:31 +00:00
|
|
|
Requires: python-setuptools
|
|
|
|
|
Requires: python-six
|
2020-05-25 08:12:04 +00:00
|
|
|
Requires(post): update-alternatives
|
|
|
|
|
Requires(postun): update-alternatives
|
2017-05-16 15:14:02 +00:00
|
|
|
# Both are providing sassc binary with different parameters
|
|
|
|
|
Conflicts: sassc
|
2020-04-15 13:01:39 +00:00
|
|
|
# SECTION test requirements
|
|
|
|
|
BuildRequires: %{python_module Werkzeug}
|
|
|
|
|
BuildRequires: %{python_module pytest}
|
|
|
|
|
# /SECTION
|
2017-05-16 15:14:02 +00:00
|
|
|
%python_subpackages
|
|
|
|
|
|
2016-01-12 15:08:31 +00:00
|
|
|
%description
|
|
|
|
|
A straightforward binding of libsass for Python. Compile Sass/SCSS in Python
|
|
|
|
|
with no Ruby stack at all!
|
|
|
|
|
|
|
|
|
|
%prep
|
2019-04-05 11:42:33 +00:00
|
|
|
%setup -q -n %{_name}-%{version}
|
2016-01-12 15:08:31 +00:00
|
|
|
|
|
|
|
|
%build
|
2019-04-05 11:42:33 +00:00
|
|
|
export SYSTEM_SASS=true
|
2017-05-16 15:14:02 +00:00
|
|
|
%python_build
|
2016-01-12 15:08:31 +00:00
|
|
|
|
|
|
|
|
%install
|
2019-04-05 11:42:33 +00:00
|
|
|
export SYSTEM_SASS=true
|
2017-05-16 15:14:02 +00:00
|
|
|
%python_install
|
2020-05-25 08:12:04 +00:00
|
|
|
%python_clone -a %{buildroot}%{_bindir}/sassc
|
|
|
|
|
%python_clone -a %{buildroot}%{_bindir}/pysassc
|
2017-05-16 15:14:02 +00:00
|
|
|
%python_expand %fdupes %{buildroot}%{$python_sitearch}
|
2016-01-12 15:08:31 +00:00
|
|
|
|
2020-04-15 13:01:39 +00:00
|
|
|
%check
|
|
|
|
|
%pytest_arch sasstests.py
|
|
|
|
|
|
2020-05-25 08:12:04 +00:00
|
|
|
%post
|
|
|
|
|
%python_install_alternative sassc
|
|
|
|
|
%python_install_alternative pysassc
|
|
|
|
|
|
|
|
|
|
%postun
|
|
|
|
|
%python_uninstall_alternative sassc
|
|
|
|
|
%python_uninstall_alternative pysassc
|
|
|
|
|
|
2019-04-05 11:42:33 +00:00
|
|
|
%files %{python_files}
|
2020-05-25 08:12:04 +00:00
|
|
|
%python_alternative %{_bindir}/pysassc
|
|
|
|
|
%python_alternative %{_bindir}/sassc
|
2019-04-05 11:42:33 +00:00
|
|
|
%{python_sitearch}/*
|
2016-01-12 15:08:31 +00:00
|
|
|
|
|
|
|
|
%changelog
|