diff --git a/.gitignore b/.gitignore index e69de29..86213a2 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/numpy-stl-2.0.0.tar.gz diff --git a/python-numpy-stl.spec b/python-numpy-stl.spec new file mode 100644 index 0000000..2fe3d76 --- /dev/null +++ b/python-numpy-stl.spec @@ -0,0 +1,80 @@ +%global pypi_name numpy-stl + +Name: python-%{pypi_name} +Version: 2.0.0 +Release: 1%{?dist} +Summary: Library for reading, writing and modifying STL files + +License: BSD +URL: https://github.com/WoLpH/numpy-stl/ +Source0: https://files.pythonhosted.org/packages/source/n/%{pypi_name}/%{pypi_name}-%{version}.tar.gz + +BuildRequires: python3-devel +BuildRequires: python3-Cython +BuildRequires: python3-nine +BuildRequires: python3-numpy +BuildRequires: python3-pytest +BuildRequires: python3-pytest-runner +BuildRequires: python3-setuptools +BuildRequires: python3-sphinx +BuildRequires: python3-utils >= 1.6.2 + +%description +Simple library to make working with STL files (and 3D objects in general) fast +and easy. Due to all operations heavily relying on numpy this is one of the +fastest STL editing libraries for Python available. + +%package -n python3-%{pypi_name} +Summary: %{summary} +%{?python_provide:%python_provide python3-%{pypi_name}} + +Requires: python3-numpy +Requires: python3-nine +Requires: python3-utils >= 1.6.2 +Requires: python3-setuptools + +%description -n python3-%{pypi_name} +Simple library to make working with STL files (and 3D objects in general) fast +and easy. Due to all operations heavily relying on NumPy this is one of the +fastest STL editing libraries for Python available. + +%package doc +Summary: %{name} documentation +Suggests: python3-%{pypi_name} +%description doc +Documentation for %{name}. + +%prep +%autosetup -n %{pypi_name}-%{version} +# Remove bundled egg-info +rm -rf %{pypi_name}.egg-info + +%build +%py3_build +# generate html docs +sphinx-build-3 docs html +# remove the sphinx-build leftovers +rm -rf html/.{doctrees,buildinfo} + +%install +%py3_install + + +%check +%{__python3} setup.py pytest + + +%files -n python3-%{pypi_name} +%doc README.rst +%{_bindir}/stl +%{_bindir}/stl2bin +%{_bindir}/stl2ascii +%{python3_sitearch}/stl +%{python3_sitearch}/numpy_stl-%{version}-py?.?.egg-info + +%files doc +%doc html + +%changelog +* Sun Dec 04 2016 Miro HronĨok - 2.0.0-1 +- Initial package diff --git a/sources b/sources index e69de29..2dca24a 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +SHA512 (numpy-stl-2.0.0.tar.gz) = f4cbbe7b02c2d48c8a4736f4c840d47cee3e164aa36546202c117db67e445c76d070f9a3434b9829096d68dbd8da88e83a1f516ad0b98361e75c2c140de873bb