%global checkout 4167eca Name: python3-mypy # Last actual version was 0.2.0, which is 7805b2c, continues as 0.2.0_dev Version: 0.2.0 Release: 1.dev20151217git%{?dist} Summary: A static type checker for Python %{?python_provide:%python_provide python3-mypy} # The files under lib-python and lib-typing/3.2 are Python-licensed, but this # package does not include those files License: MIT URL: https://github.com/JukkaL/mypy # git archive --prefix=mypy-0.2.0-4167eca/ 4167eca | gzip -c9 > mypy-0.2.0-4167eca.tar.gz Source0: mypy-%{version}-%{checkout}.tar.gz # The bundled typing.py is not needed with python 3.5 Patch0: 0001-Do-not-install-typing.py.patch # Change the search for data_dir to use Fedora's typeshed package instead of a # bundled version Patch1: 0002-Look-for-typeshed-in-usr-share.patch BuildRequires: python3-devel # Needed to generate the man pages BuildRequires: help2man Requires: python-typeshed BuildArch: noarch %description Mypy is an optional static type checker for Python. You can add type hints to your Python programs using the upcoming standard for type annotations introduced in Python 3.5 beta 1 (PEP 484), and use mypy to type check them statically. Find bugs in your programs without even running them! %prep %autosetup -n mypy-%{version}-%{checkout} -p1 %build %py3_build %install %py3_install # Generate man pages mkdir -p %{buildroot}%{_mandir}/man1 PYTHONPATH=%{buildroot}%{python3_sitelib} \ help2man --no-info --version-string 'mypy %{version}-dev' \ --no-discard-stderr -o %{buildroot}%{_mandir}/man1/mypy.1 \ %{buildroot}%{_bindir}/mypy PYTHONPATH=%{buildroot}%{python3_sitelib} \ help2man --no-info --version-string 'mypy stubgen %{version}-dev' \ --no-discard-stderr -o %{buildroot}%{_mandir}/man1/stubgen.1 \ %{buildroot}%{_bindir}/stubgen %files %doc README.md CREDITS %license LICENSE %{python3_sitelib}/mypy %{python3_sitelib}/mypy_lang-*.egg-info %{_bindir}/mypy %{_bindir}/stubgen %{_mandir}/man1/mypy.1* %{_mandir}/man1/stubgen.1* # distutils insists on putting data_files in /usr/lib, so just go with it %{_prefix}/lib/mypy %changelog * Thu Dec 17 2015 David Shea - 0.2.0-1.dev20151217git - Initial package