diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..45a54e5 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/snuggs-1.4.1.tar.gz diff --git a/README.md b/README.md deleted file mode 100644 index a9e1e4d..0000000 --- a/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# python-snuggs - -The python-snuggs package \ No newline at end of file diff --git a/python-snuggs.spec b/python-snuggs.spec new file mode 100644 index 0000000..4a9ef48 --- /dev/null +++ b/python-snuggs.spec @@ -0,0 +1,95 @@ +%global srcname snuggs + +Name: python-%{srcname} +Version: 1.4.1 +Release: 1%{?dist} +Summary: Snuggs are S-expressions for Numpy + +License: MIT +URL: https://github.com/mapbox/snuggs +# No tests in PyPI tarball. +Source0: https://github.com/mapbox/snuggs/archive/%{version}/%{srcname}-%{version}.tar.gz + +BuildArch: noarch + +%global _description \ +Snuggs are S-expressions for NumPy. Snuggs wraps NumPy in expressions with the \ +following syntax: expression "(" (operator | function) *arg ")" where \ +arg = expression | name | number | string + +%description %{_description} + + +%package -n python2-%{srcname} +Summary: %{summary} +%{?python_provide:%python_provide python2-%{srcname}} + +BuildRequires: python2-devel +BuildRequires: python2-setuptools +BuildRequires: python2-pytest +BuildRequires: python2-click +BuildRequires: python2-numpy +BuildRequires: python2-pyparsing + +Requires: python2-click +Requires: python2-numpy +Requires: python2-pyparsing + +%description -n python2-%{srcname} %{_description} + + +%package -n python3-%{srcname} +Summary: %{summary} +%{?python_provide:%python_provide python3-%{srcname}} + +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pytest +BuildRequires: python3-click +BuildRequires: python3-numpy +BuildRequires: python3-pyparsing + +Requires: python3-click +Requires: python3-numpy +Requires: python3-pyparsing +%description -n python3-%{srcname} %{_description} + + +%prep +%autosetup -n %{srcname}-%{version} + +# Remove bundled egg-info +rm -rf %{srcname}.egg-info + + +%build +%py2_build +%py3_build + + +%install +%py2_install +%py3_install + + +%check +pytest-3 -v +pytest-2 -v + + +%files -n python2-%{srcname} +%doc README.rst AUTHORS.txt CHANGES.txt +%license LICENSE +%{python2_sitelib}/%{srcname} +%{python2_sitelib}/%{srcname}-%{version}-py?.?.egg-info + +%files -n python3-%{srcname} +%doc README.rst AUTHORS.txt CHANGES.txt +%license LICENSE +%{python3_sitelib}/%{srcname} +%{python3_sitelib}/%{srcname}-%{version}-py?.?.egg-info + + +%changelog +* Sat Jan 13 2018 Elliott Sales de Andrade - 1.4.1-1 +- Initial package. diff --git a/sources b/sources new file mode 100644 index 0000000..cc377ee --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (snuggs-1.4.1.tar.gz) = 9760fec33131138a2d6ca0e9571ab3843d754a943b90549822db7516fe6ef93be74334946249cb671783f8d437757b3994714c09b48a2f6bcbb6eeeb8e59bc85