commit 1588ee5b5c0c1bbb14c0c6584316c6e261bd47d6
Author: Elan Ruusamäe <[email protected]>
Date:   Fri Mar 11 23:41:32 2016 +0200

    up to 2.0.0

 default-distro.patch   | 17 +++++++----------
 default-savepath.patch |  8 ++++----
 pyp2rpm.spec           | 34 ++++++++++++++++------------------
 3 files changed, 27 insertions(+), 32 deletions(-)
---
diff --git a/pyp2rpm.spec b/pyp2rpm.spec
index 4e92412..3be2c20 100644
--- a/pyp2rpm.spec
+++ b/pyp2rpm.spec
@@ -1,30 +1,31 @@
 #
 # Conditional build:
-%bcond_without tests   # do not perform "make test"
+%bcond_with    tests   # do not perform "make test"
 
 Summary:       Convert Python packages to RPM .spec files
 Name:          pyp2rpm
-Version:       1.1.2
-Release:       1
+Version:       2.0.0
+Release:       0.1
 License:       MIT
 Group:         Applications
 Source0:       
http://pypi.python.org/packages/source/p/pyp2rpm/%{name}-%{version}.tar.gz
-# Source0-md5: c53728da205a0c9b8860644de464ea0d
+# Source0-md5: 935066a6d90f13f673753c0ce27d98e0
 # to get tests:
 # git clone [email protected]:bkabrda/pyp2rpm.git && cd pyp2rpm
 # git checkout v1.0.1 && tar czf pyp2rpm-1.0.1-tests.tgz tests/
-Source1:       
http://pkgs.fedoraproject.org/repo/pkgs/pyp2rpm/%{name}-%{version}-tests.tgz/159412b3603fdcc673c0a8c731bc22c4/pyp2rpm-%{version}-tests.tgz
-# Source1-md5: 159412b3603fdcc673c0a8c731bc22c4
+#Source1:      
http://pkgs.fedoraproject.org/repo/pkgs/pyp2rpm/%{name}-%{version}-tests.tgz/159412b3603fdcc673c0a8c731bc22c4/pyp2rpm-%{version}-tests.tgz
+## Source1-md5:        159412b3603fdcc673c0a8c731bc22c4
 Source2:       pld.spec.tmpl
 Patch0:                default-savepath.patch
 Patch1:                no-rpmdev-packager.patch
 Patch2:                default-distro.patch
-URL:           https://pypi.python.org/pypi/pyp2rpm
+URL:           https://github.com/fedora-python/pyp2rpm
 BuildRequires: python-flexmock >= 0.9.3
 BuildRequires: python-pytest
 BuildRequires: python-setuptools
 BuildRequires: rpm-pythonprov
-BuildRequires: rpmbuild(macros) >= 1.219
+BuildRequires: rpmbuild(macros) >= 1.714
+Requires:      python-click
 Requires:      python-jinja2
 Requires:      python-setuptools
 BuildArch:     noarch
@@ -43,13 +44,14 @@ information though).
 %patch0 -p1
 %patch1 -p1
 %patch2 -p1
+
 # Remove bundled egg-info
 rm -r %{name}.egg-info
 
-cp -p %{SOURCE2} pyp2rpm/templates/pld.spec
+#cp -p %{SOURCE2} pyp2rpm/templates/pld.spec
 
 %build
-%{__python} setup.py build
+%py_build
 
 %if %{with tests}
 PYTHONPATH=$(pwd) py.test
@@ -57,11 +59,7 @@ PYTHONPATH=$(pwd) py.test
 
 %install
 rm -rf $RPM_BUILD_ROOT
-%{__python} setup.py install \
-       --skip-build \
-       --optimize=2 \
-       --root=$RPM_BUILD_ROOT
-
+%py_install
 %py_postclean
 
 %clean
@@ -69,14 +67,14 @@ rm -rf $RPM_BUILD_ROOT
 
 %files
 %defattr(644,root,root,755)
-%doc README.rst LICENSE
+%doc LICENSE
 %attr(755,root,root) %{_bindir}/pyp2rpm
 %dir %{py_sitescriptdir}/%{name}
 %{py_sitescriptdir}/%{name}/*.py[co]
 %dir %{py_sitescriptdir}/%{name}/templates
-%{py_sitescriptdir}/%{name}/templates/macros.spec
 %{py_sitescriptdir}/%{name}/templates/fedora.spec
+%{py_sitescriptdir}/%{name}/templates/fedora_subdirs.spec
+%{py_sitescriptdir}/%{name}/templates/macros.spec
 %{py_sitescriptdir}/%{name}/templates/mageia.spec
 %{py_sitescriptdir}/%{name}/templates/pld.spec
 %{py_sitescriptdir}/%{name}-%{version}-py*.egg-info
-
diff --git a/default-distro.patch b/default-distro.patch
index 6beeb92..67e25a5 100644
--- a/default-distro.patch
+++ b/default-distro.patch
@@ -1,5 +1,5 @@
---- pyp2rpm-1.1.2/README.rst~  2014-11-10 14:44:08.000000000 +0200
-+++ pyp2rpm-1.1.2/README.rst   2015-05-23 13:29:02.046296448 +0300
+#--- pyp2rpm-1.1.2/README.rst~ 2014-11-10 14:44:08.000000000 +0200
+#+++ pyp2rpm-1.1.2/README.rst  2015-05-23 13:29:02.046296448 +0300
 @@ -37,8 +37,8 @@
        -s PACKAGE_SOURCE   Where to get package from ("pypi" or 
"/full/path/to/local/file", default: "pypi").
        -d SAVE_DIR         Where to save the package file (default: 
"~/rpmbuild")
@@ -11,10 +11,10 @@
        -b BASE_PYTHON      Base Python version to package for (default: "2").
        -p PYTHON_VERSION   Additional Python versions to include in the 
specfile (e.g -p3 for %{?with_python3}). Can be specified multiple times.
        --srpm              When used pyp2rpm will produce srpm instead of 
printing specfile into stdout.
---- pyp2rpm-1.0.1/./pyp2rpm/settings.py~       2013-03-17 05:02:54.000000000 
+0200
-+++ pyp2rpm-1.0.1/./pyp2rpm/settings.py        2013-03-17 12:04:45.524371795 
+0200
-@@ -3,10 +3,10 @@
- DEFAULT_PYTHON_VERSION = '2'
+--- pyp2rpm-2.0.0/pyp2rpm/settings.py~ 2016-03-11 23:24:36.000000000 +0200
++++ pyp2rpm-2.0.0/pyp2rpm/settings.py  2016-03-11 23:25:04.213223094 +0200
+@@ -4,8 +4,8 @@
+ DEFAULT_ADDITIONAL_VERSION = '3'
  DEFAULT_PKG_SOURCE = 'pypi'
  DEFAULT_METADATA_SOURCE = 'pypi'
 -DEFAULT_TEMPLATE = 'fedora'
@@ -22,8 +22,5 @@
 +DEFAULT_TEMPLATE = 'pld'
 +DEFAULT_DISTRO = 'pld'
  DEFAULT_PKG_SAVE_PATH = os.path.expanduser('.')
--KNOWN_DISTROS = ['fedora', 'mageia']
-+KNOWN_DISTROS = ['pld','fedora', 'mageia']
+ KNOWN_DISTROS = ['fedora', 'mageia', 'pld']
  ARCHIVE_SUFFIXES = ['.tar', '.tgz', '.tar.gz', '.tar.bz2', '.gz', '.bz2', 
'.zip', '.egg']
- EXTENSION_SUFFIXES = ['.c', '.cpp']
- DOC_FILES_RE = [r'readme.+', r'licens.+', r'copying.+']
diff --git a/default-savepath.patch b/default-savepath.patch
index dd18141..3d7ad3f 100644
--- a/default-savepath.patch
+++ b/default-savepath.patch
@@ -1,11 +1,11 @@
---- pyp2rpm-1.1.2/pyp2rpm/settings.py~ 2014-10-27 11:39:52.000000000 +0200
-+++ pyp2rpm-1.1.2/pyp2rpm/settings.py  2015-05-23 13:25:29.638625642 +0300
-@@ -5,7 +5,7 @@
+--- pyp2rpm-2.0.0/pyp2rpm/settings.py~ 2015-08-10 11:11:04.000000000 +0300
++++ pyp2rpm-2.0.0/pyp2rpm/settings.py  2016-03-11 23:23:40.392220994 +0200
+@@ -6,7 +6,7 @@
  DEFAULT_METADATA_SOURCE = 'pypi'
  DEFAULT_TEMPLATE = 'fedora'
  DEFAULT_DISTRO = 'fedora'
 -DEFAULT_PKG_SAVE_PATH = os.path.expanduser('~/rpmbuild')
 +DEFAULT_PKG_SAVE_PATH = os.path.expanduser('.')
- KNOWN_DISTROS = ['fedora', 'mageia']
+ KNOWN_DISTROS = ['fedora', 'mageia', 'pld']
  ARCHIVE_SUFFIXES = ['.tar', '.tgz', '.tar.gz', '.tar.bz2', '.gz', '.bz2', 
'.zip', '.egg']
  EXTENSION_SUFFIXES = ['.c', '.cpp']
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/pyp2rpm.git/commitdiff/f8fb92c0f8863590e1e71171a092ad1dc12bc4d9

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to