File python-pyLD.spec of Package python-pyLD
#
# spec file for package python-pyLD
#
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
#
# 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 http://bugs.opensuse.org/
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%bcond_with test
Name: python-pyLD
Version: 0.8.2
Release: 0
Summary: Implementation if the JSON-LD specification in Python
License: BSD-2-Clause
Group: Development/Languages/Python
Url: https://pypi.python.org/pypi/PyLD/%{version}
Source: https://pypi.python.org/packages/9d/3d/cbfaaa7874d53a5d3b66a9b643840ad96a5681a96d5231e574f96ea0e333/PyLD-0.8.2.tar.gz
BuildRequires: %{python_module devel}
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
%if %{with test}
BuildRequires: %{python_module requests}
BuildRequires: python-mock
%endif
Requires: python-requests
BuildArch: noarch
%python_subpackages
%description
JSON-LD is designed as a light-weight syntax that can be used to express Linked Data. It is primarily intended to be a way to express Linked Data in JavaScript and other Web-based programming environments. It is also useful when building interoperable Web Services and when storing Linked Data in JSON-based document storage engines.
%prep
%setup -q -n PyLD-%{version}
%build
%python_build
%install
%python_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%if %{with test}
%check
%{python_expand export PYTHONPATH=%{buildroot}%{$python_sitelib}
py.test-%{$python_bin_suffix}
}
%endif
%files %{python_files}
%defattr(-,root,root,-)
%doc LICENSE README.rst CHANGELOG.md
%{python_sitelib}/pyld/
%{python_sitelib}/PyLD-%{version}-py*.egg-info
%changelog