diff --git a/kivy-1.10.1.tar.gz b/kivy-1.10.1.tar.gz new file mode 100644 index 0000000..a35c4f2 --- /dev/null +++ b/kivy-1.10.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:794e45cc7bcc7882f7cd95f1673bc6701f3215a20a54c915cac0c5e46a449b4c +size 24318169 diff --git a/kivy-1.9.1.tar.gz b/kivy-1.9.1.tar.gz deleted file mode 100644 index f5a818b..0000000 --- a/kivy-1.9.1.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:29bc45be34c26a8acb1dafdd329145f997a473be344cd052659f821f6478637e -size 16363833 diff --git a/python-Kivy-rpmlintrc b/python-Kivy-rpmlintrc deleted file mode 100644 index 51bd5ee..0000000 --- a/python-Kivy-rpmlintrc +++ /dev/null @@ -1,4 +0,0 @@ -# Is this just a noise or real -addFilter("no-dependency-on python.abi."); -# upstream problem... -addFilter("incorrect-fsf-address .*kivy-mode.el"); diff --git a/python-Kivy.changes b/python-Kivy.changes index f9b3159..eed97eb 100644 --- a/python-Kivy.changes +++ b/python-Kivy.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Sat Jul 7 07:40:43 UTC 2018 - aloisio@gmx.com + +- Update to version 1.10.1 (see https://kivy.org/#changelog) +- Converted to single-spec +- Put documentation and examples into -doc subpackage +- Dropped python-Kivy-rpmlintrc + ------------------------------------------------------------------- Sat Mar 11 21:44:53 UTC 2017 - sfalken@opensuse.org diff --git a/python-Kivy.spec b/python-Kivy.spec index 4973cc2..061c591 100644 --- a/python-Kivy.spec +++ b/python-Kivy.spec @@ -1,7 +1,7 @@ # # spec file for package python-Kivy # -# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2018 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 @@ -16,121 +16,135 @@ # +%{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-Kivy -Version: 1.9.1 +Version: 1.10.1 Release: 0 -Url: http://kivy.org/ Summary: Hardware-accelerated multitouch application library -License: LGPL-3.0 +License: MIT AND Apache-2.0 AND LGPL-2.1-or-later AND GPL-2.0-or-later AND GPL-3.0-only AND BSD-3-Clause Group: Development/Languages/Python -Source0: https://pypi.python.org/packages/source/K/Kivy/kivy-%{version}.tar.gz -# -# Suppressing wrong fsf address and python abi warnings - not really relevant -# -Source1: python-Kivy-rpmlintrc -BuildRoot: %{_tmppath}/%{name}-%{version}-build +URL: https://kivy.org/ +Source: https://github.com/kivy/kivy/archive/%{version}.tar.gz#/kivy-%{version}.tar.gz +BuildRequires: %{python_module Cython} +BuildRequires: %{python_module Pillow} +BuildRequires: %{python_module coverage} +BuildRequires: %{python_module dbus-python} +BuildRequires: %{python_module devel} +BuildRequires: %{python_module docutils} +BuildRequires: %{python_module mock} +BuildRequires: %{python_module nose} +BuildRequires: %{python_module pyenchant} +BuildRequires: %{python_module pygments} BuildRequires: Mesa-devel -%if 0%{?suse_version} > 1310 +BuildRequires: Mesa-dri BuildRequires: SDL2-devel BuildRequires: SDL2_image-devel BuildRequires: SDL2_mixer-devel BuildRequires: SDL2_ttf-devel -%endif +BuildRequires: dbus-1 BuildRequires: fdupes -BuildRequires: gstreamer-devel +BuildRequires: gstreamer-plugins-bad +BuildRequires: gstreamer-plugins-good BuildRequires: mtdev -BuildRequires: pkg-config -BuildRequires: python-Cython -BuildRequires: python-Pillow -BuildRequires: python-Sphinx -BuildRequires: python-devel -BuildRequires: python-opengl -BuildRequires: python-pyenchant -BuildRequires: python-pygame +BuildRequires: pkgconfig +BuildRequires: python-rpm-macros +BuildRequires: python3-Sphinx +BuildRequires: xclip +BuildRequires: xvfb-run +BuildRequires: pkgconfig(gstreamer-1.0) Requires: mtdev Requires: python-Pillow -Requires: python-opengl +Requires: python-Pygments +Requires: python-docutils Requires: python-pyenchant -Requires: python-pygame +Requires: xclip Recommends: python-opencv -%if 0%{?suse_version} && 0%{?suse_version} <= 1110 -%{!?python_sitearch: %global python_sitearch %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")} -%endif +%python_subpackages %description Kivy is an open source software library for rapid development of applications that make use of innovative user interfaces, such as multi-touch apps. -%package doc -Summary: Documentation for %{name} -Group: Documentation/Other -Requires: %{name} = %{version} - -%description doc -Kivy is an open source software library for rapid development of applications -that make use of innovative user interfaces, such as multi-touch apps. - -This package contains the developer documentation and examples - -%package devel +%package devel Summary: Development files for %{name} Group: Development/Languages/Python Requires: %{name} = %{version} -%description devel +%description devel Kivy is an open source software library for rapid development of applications that make use of innovative user interfaces, such as multi-touch apps. This package contains the headers and source files for extending kivy +%package -n %{name}-doc +Summary: Hardware-accelerated multitouch application library - Documentation +Group: Development/Languages/Python +Provides: %{python_module Kivy-doc = %{version}} + +%description -n %{name}-doc +Kivy is an open source software library for rapid development of applications +that make use of innovative user interfaces, such as multi-touch apps. + %prep %setup -q -n kivy-%{version} - -sed -i "s|data_file_prefix = 'share/kivy-'|data_file_prefix = '%{_docdir}/%{name}/'|" setup.py -sed -i "s|#!/usr/bin/python||" kivy/lib/osc/OSC.py # Fix non-executable script +sed -i "s|data_file_prefix = 'share/kivy-'|data_file_prefix = '%{_docdir}/%{name}-doc/'|" setup.py +# remove shebang +sed -i '1{ /^#!/d; }' kivy/tools/kviewer.py \ + kivy/tools/pep8checker/pep8.py \ + kivy/tools/pep8checker/pre-commit.githook +# remove executable bit +find examples -type f -executable -exec chmod -x {} \; rm examples/demo/pictures/images/.empty # Remove empty file rm -r examples/audio # Remove content with non-commercial only license (bnc#749340) -find examples -name android.txt -exec chmod 644 {} \; - -#drop usr/bin/kivy shebang to not produce dependency on itself -sed -i 's@#!/usr/bin/kivy@#!/usr/bin/env kivy@' \ - examples/demo/showcase/main.py \ - examples/demo/kivycatalog/main.py \ - examples/demo/pictures/main.py \ - examples/demo/shadereditor/main.py \ - examples/demo/touchtracer/main.py %build -CFLAGS="%{optflags} -fno-strict-aliasing" python setup.py build -cd doc && make html && rm -r build/html/.buildinfo # Build HTML documentation +export CFLAGS="%{optflags} -fno-strict-aliasing" +%python_build bdist +# create docs +pushd doc +sed -e '/^PYTHON/s/python/python3/' \ + -e '/^SPHINXOPTS /s/$/ %{?_smp_mflags}/' \ + -i Makefile +export PYTHONPATH=`ls -d ../build/lib*` +make html && rm -r build/html/.buildinfo +popd %install -install -dm0755 %{buildroot}%{_defaultdocdir}/%{name}-doc -python setup.py install --prefix=%{_prefix} --root=%{buildroot} +%python_install # workaround to make fdupes its magic as if %%doc macro is used # would be used after fdupes so rpmlint would complain about duplicates... -cp -a examples %{buildroot}%{_defaultdocdir}/%{name}-doc +install -dm0755 %{buildroot}%{_defaultdocdir}/%{name}-doc +cp -a doc/build/html %{buildroot}/%{_defaultdocdir}/%{name}-doc -%fdupes %{buildroot}%{_defaultdocdir} -%fdupes %{buildroot}%{python_sitearch} +%python_expand %fdupes -s %{buildroot}%{$python_sitearch}/kivy +%fdupes -s %{buildroot}%{_defaultdocdir}/%{name}-doc -%files -%defattr(-,root,root,-) -%doc AUTHORS LICENSE -%doc %{_docdir}/%{name} -%{python_sitearch}/kivy/ +%check +export DISPLAY=:99.0 +export KIVY_AUDIO=gstplayer # "unable to find ffpyplayer" otherwise +export LANG=en_US.UTF-8 +%{python_expand pushd %{buildroot}%{$python_sitearch} +ln -s %{buildroot}%{_defaultdocdir}/%{name}-doc/examples examples +ln -s %{_builddir}/kivy-%{version}/doc . +xvfb-run --server-args "-screen 0 1920x1080x24" $python %{_bindir}/nosetests kivy.tests \ + -e test_urlrequest -e test_remote_zipsequence +rm examples doc results.png +popd +} + +%files %{python_files} +%license LICENSE +%doc AUTHORS +%{python_sitearch}/kivy %{python_sitearch}/Kivy-%{version}-py*.egg-info -%exclude %{python_sitearch}/kivy/graphics/*.h +%exclude %{python_sitearch}/kivy/include %exclude %{python_sitearch}/kivy/tools/gles_compat/gl2.h -%files doc -%defattr(644,root,root,-) -%doc doc/build/html -%{_defaultdocdir}/%{name}-doc - -%files devel -%defattr(644,root,root,-) -%{python_sitearch}/kivy/graphics/*.h +%files %{python_files devel} +%{python_sitearch}/kivy/include %{python_sitearch}/kivy/tools/gles_compat/gl2.h +%files -n %{name}-doc +%doc %{_defaultdocdir}/%{name}-doc + %changelog