Change-Id: Ic6c1d7dfdc44eb0bd52e252846b55a79968adaf3
Reviewed-on: http://photon-jenkins.eng.vmware.com:8082/2740
Tested-by: gerrit-photon <photon-checkins@vmware.com>
Reviewed-by: Alexey Makhalov <amakhalov@vmware.com>
| ... | ... |
@@ -1,7 +1,10 @@ |
| 1 |
+%{!?python2_sitelib: %define python2_sitelib %(python2 -c "from distutils.sysconfig import get_python_lib;print(get_python_lib())")}
|
|
| 2 |
+%{!?python3_sitelib: %define python3_sitelib %(python3 -c "from distutils.sysconfig import get_python_lib;print(get_python_lib())")}
|
|
| 3 |
+ |
|
| 1 | 4 |
Summary: Hawkey |
| 2 | 5 |
Name: hawkey |
| 3 | 6 |
Version: 2017.1 |
| 4 |
-Release: 1%{?dist}
|
|
| 7 |
+Release: 2%{?dist}
|
|
| 5 | 8 |
License: LGPLv2+ |
| 6 | 9 |
URL: http://fedoraproject.org/wiki/Features/Hawkey |
| 7 | 10 |
Source0: https://github.com/rpm-software-management/hawkey/archive/%{name}-%{version}.tar.gz
|
| ... | ... |
@@ -44,16 +47,43 @@ Requires: python2 |
| 44 | 44 |
%description -n python-hawkey |
| 45 | 45 |
Python 2 bindings for the hawkey library. |
| 46 | 46 |
|
| 47 |
+%package -n python3-%{name}
|
|
| 48 |
+Summary: Python 3 bindings for the hawkey library |
|
| 49 |
+%{?python_provide:%python_provide python3-%{name}}
|
|
| 50 |
+BuildRequires: python3-devel |
|
| 51 |
+BuildRequires: python3-sphinx |
|
| 52 |
+Requires: %{name} = %{version}-%{release}
|
|
| 53 |
+ |
|
| 54 |
+%description -n python3-%{name}
|
|
| 55 |
+Python 3 bindings for the hawkey library. |
|
| 56 |
+ |
|
| 47 | 57 |
%prep |
| 48 | 58 |
%setup -qn hawkey-hawkey-0.6.4-1 |
| 49 | 59 |
sed -i 's/ADD_SUBDIRECTORY (doc)//' CMakeLists.txt |
| 60 |
+mkdir build |
|
| 61 |
+mkdir build-py3 |
|
| 50 | 62 |
%build |
| 63 |
+pushd build |
|
| 51 | 64 |
cmake \ |
| 52 |
- -DCMAKE_INSTALL_PREFIX=%{_prefix}
|
|
| 65 |
+ -DCMAKE_INSTALL_PREFIX=%{_prefix} ..
|
|
| 53 | 66 |
make %{?_smp_mflags}
|
| 67 |
+popd |
|
| 68 |
+pushd build-py3 |
|
| 69 |
+cmake \ |
|
| 70 |
+ -DCMAKE_INSTALL_PREFIX=%{_prefix} \
|
|
| 71 |
+ -DPYTHON_DESIRED:str=3 .. |
|
| 72 |
+popd |
|
| 73 |
+ |
|
| 54 | 74 |
%install |
| 75 |
+pushd build |
|
| 55 | 76 |
make DESTDIR=%{buildroot} install
|
| 56 | 77 |
find %{buildroot} -name '*.la' -delete
|
| 78 |
+popd |
|
| 79 |
+pushd build-py3 |
|
| 80 |
+make DESTDIR=%{buildroot} install
|
|
| 81 |
+find %{buildroot} -name '*.la' -delete
|
|
| 82 |
+popd |
|
| 83 |
+ |
|
| 57 | 84 |
%check |
| 58 | 85 |
cp src/libhawkey.* /lib |
| 59 | 86 |
easy_install nose |
| ... | ... |
@@ -66,7 +96,11 @@ tests/test_main tests/repos/ |
| 66 | 66 |
|
| 67 | 67 |
%files -n python-hawkey |
| 68 | 68 |
%defattr(-,root,root) |
| 69 |
-%{python_sitearch}/
|
|
| 69 |
+%{python2_sitelib}/*
|
|
| 70 |
+ |
|
| 71 |
+%files -n python3-hawkey |
|
| 72 |
+%defattr(-,root,root) |
|
| 73 |
+%{python3_sitelib}/*
|
|
| 70 | 74 |
|
| 71 | 75 |
%files devel |
| 72 | 76 |
%defattr(-,root,root) |
| ... | ... |
@@ -76,6 +110,8 @@ tests/test_main tests/repos/ |
| 76 | 76 |
%exclude %{python_sitearch}/*
|
| 77 | 77 |
|
| 78 | 78 |
%changelog |
| 79 |
+* Mon May 22 2017 Xiaolin Li <xiaolinl@vmware.com> 2017.1-2 |
|
| 80 |
+- Added python3 subpackage. |
|
| 79 | 81 |
* Wed Apr 05 2017 Dheeraj Shetty <dheerajs@vmware.com> 2017.1-1 |
| 80 | 82 |
- Upgrading to version 2017.1 which is 0.6.4-1. |
| 81 | 83 |
* Mon Dec 19 2016 Xiaolin Li <xiaolinl@vmware.com> 2014.1-6 |
| ... | ... |
@@ -1,18 +1,42 @@ |
| 1 |
+%{!?python2_sitelib: %define python2_sitelib %(python2 -c "from distutils.sysconfig import get_python_lib;print(get_python_lib())")}
|
|
| 2 |
+%{!?python3_sitelib: %define python3_sitelib %(python3 -c "from distutils.sysconfig import get_python_lib;print(get_python_lib())")}
|
|
| 3 |
+ |
|
| 1 | 4 |
Summary: POSIX capability Library |
| 2 | 5 |
Name: libcap-ng |
| 3 | 6 |
Version: 0.7.8 |
| 4 |
-Release: 1%{?dist}
|
|
| 7 |
+Release: 2%{?dist}
|
|
| 5 | 8 |
License: LGPLv2+ |
| 6 | 9 |
Group: System Environment/Libraries |
| 7 | 10 |
URL: http://people.redhat.com/sgrubb/libcap-ng |
| 8 | 11 |
Source0: http://people.redhat.com/sgrubb/libcap-ng/%{name}-%{version}.tar.gz
|
| 9 | 12 |
%define sha1 libcap-ng=59a85129dd0d062c14320f6c611696669a1cc0c0 |
| 13 |
+ |
|
| 14 |
+%description |
|
| 15 |
+The libcap-ng library is intended to make programming with posix capabilities much easier than the traditional libcap library. It includes utilities that can analyse all currently running applications and print out any capabilities and whether or not it has an open ended bounding set. An open bounding set without the securebits "NOROOT" flag will allow full capabilities escalation for apps retaining uid 0 simply by calling execve. |
|
| 16 |
+ |
|
| 17 |
+%package -n python2-libcap-ng |
|
| 18 |
+Summary: Python bindings for libcap-ng |
|
| 19 |
+License: LGPLv2+ |
|
| 10 | 20 |
BuildRequires: python2-devel |
| 11 | 21 |
BuildRequires: python2-libs |
| 22 |
+BuildRequires: swig |
|
| 23 |
+Requires: %{name} = %{version}-%{release}
|
|
| 12 | 24 |
Requires: python2 |
| 13 | 25 |
|
| 14 |
-%description |
|
| 15 |
-The libcap-ng library is intended to make programming with posix capabilities much easier than the traditional libcap library. It includes utilities that can analyse all currently running applications and print out any capabilities and whether or not it has an open ended bounding set. An open bounding set without the securebits "NOROOT" flag will allow full capabilities escalation for apps retaining uid 0 simply by calling execve. |
|
| 26 |
+%description -n python2-libcap-ng |
|
| 27 |
+The python2-libcap-ng package contains the python2 bindings for libcap-ng. |
|
| 28 |
+ |
|
| 29 |
+%package -n python3-libcap-ng |
|
| 30 |
+Summary: Python3 bindings for libaudit |
|
| 31 |
+License: LGPLv2+ |
|
| 32 |
+BuildRequires: python3-devel |
|
| 33 |
+BuildRequires: python3-libs |
|
| 34 |
+BuildRequires: swig |
|
| 35 |
+Requires: %{name} = %{version}-%{release}
|
|
| 36 |
+Requires: python3 |
|
| 37 |
+ |
|
| 38 |
+%description -n python3-libcap-ng |
|
| 39 |
+The python3-libcap-ng package contains the python3 bindings for libcap-ng. |
|
| 16 | 40 |
|
| 17 | 41 |
%package devel |
| 18 | 42 |
Summary: The libraries and header files needed for libcap-ng development. |
| ... | ... |
@@ -29,11 +53,12 @@ The libraries and header files needed for libcap_ng development. |
| 29 | 29 |
--prefix=%{_prefix} \
|
| 30 | 30 |
--libdir=%{_libdir} \
|
| 31 | 31 |
--with-python \ |
| 32 |
- --without-python3 |
|
| 32 |
+ --with-python3 |
|
| 33 | 33 |
|
| 34 | 34 |
make %{?_smp_mflags}
|
| 35 | 35 |
%install |
| 36 |
-make DESTDIR=%{buildroot} install
|
|
| 36 |
+make DESTDIR=%{buildroot} install
|
|
| 37 |
+find %{buildroot} -name '*.la' -delete
|
|
| 37 | 38 |
|
| 38 | 39 |
%check |
| 39 | 40 |
chown -Rv nobody . |
| ... | ... |
@@ -45,11 +70,14 @@ sudo -u nobody -s /bin/bash -c "PATH=$PATH make -k check" |
| 45 | 45 |
%files |
| 46 | 46 |
%defattr(-, root, root) |
| 47 | 47 |
%{_libdir}/*.so.*
|
| 48 |
-%{_libdir}/*.a
|
|
| 49 |
-%{_libdir}/*.la
|
|
| 50 | 48 |
%{_bindir}/*
|
| 51 | 49 |
%{_mandir}/man8/*
|
| 52 |
-%{_datadir}/aclocal/*.m4
|
|
| 50 |
+ |
|
| 51 |
+%files -n python2-libcap-ng |
|
| 52 |
+%{python2_sitelib}/*
|
|
| 53 |
+ |
|
| 54 |
+%files -n python3-libcap-ng |
|
| 55 |
+%{python3_sitelib}/*
|
|
| 53 | 56 |
|
| 54 | 57 |
%files devel |
| 55 | 58 |
%defattr(-, root, root) |
| ... | ... |
@@ -57,8 +85,12 @@ sudo -u nobody -s /bin/bash -c "PATH=$PATH make -k check" |
| 57 | 57 |
%{_libdir}/pkgconfig/*.pc
|
| 58 | 58 |
%{_includedir}/*.h
|
| 59 | 59 |
%{_mandir}/man3/*
|
| 60 |
+%{_datadir}/aclocal/*.m4
|
|
| 61 |
+%{_libdir}/*.a
|
|
| 60 | 62 |
|
| 61 | 63 |
%changelog |
| 64 |
+* Mon May 22 2017 Xiaolin Li <xiaolinl@vmware.com> 0.7.8-2 |
|
| 65 |
+- Added python3 subpackage. |
|
| 62 | 66 |
* Mon Apr 03 2017 Divya Thaluru <dthaluru@vmware.com> 0.7.8-1 |
| 63 | 67 |
- Upgrade version to 0.7.8 |
| 64 | 68 |
* Wed Dec 07 2016 Xiaolin Li <xiaolinl@vmware.com> 0.7.7-3 |
| 65 | 69 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,31 @@ |
| 0 |
+diff --git a/iniparse/compat.py b/iniparse/compat.py |
|
| 1 |
+index db89ed8..09ffa23 100644 |
|
| 2 |
+--- a/iniparse/compat.py |
|
| 3 |
+@@ -56,7 +56,7 @@ class RawConfigParser(object): |
|
| 4 |
+ # The default section is the only one that gets the case-insensitive |
|
| 5 |
+ # treatment - so it is special-cased here. |
|
| 6 |
+ if section.lower() == "default": |
|
| 7 |
+- raise ValueError, 'Invalid section name: %s' % section |
|
| 8 |
++ raise ValueError('Invalid section name: %s' % section)
|
|
| 9 |
+ |
|
| 10 |
+ if self.has_section(section): |
|
| 11 |
+ raise DuplicateSectionError(section) |
|
| 12 |
+@@ -143,7 +143,7 @@ class RawConfigParser(object): |
|
| 13 |
+ def getboolean(self, section, option): |
|
| 14 |
+ v = self.get(section, option) |
|
| 15 |
+ if v.lower() not in self._boolean_states: |
|
| 16 |
+- raise ValueError, 'Not a boolean: %s' % v |
|
| 17 |
++ raise ValueError('Not a boolean: %s' % v)
|
|
| 18 |
+ return self._boolean_states[v.lower()] |
|
| 19 |
+ |
|
| 20 |
+ def has_option(self, section, option): |
|
| 21 |
+@@ -234,7 +234,7 @@ class ConfigParser(RawConfigParser): |
|
| 22 |
+ if "%(" in value:
|
|
| 23 |
+ try: |
|
| 24 |
+ value = value % vars |
|
| 25 |
+- except KeyError, e: |
|
| 26 |
++ except KeyError as e: |
|
| 27 |
+ raise InterpolationMissingOptionError( |
|
| 28 |
+ option, section, rawval, e.args[0]) |
|
| 29 |
+ else: |
| ... | ... |
@@ -1,20 +1,22 @@ |
| 1 |
-%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
|
|
| 1 |
+%{!?python2_sitelib: %define python2_sitelib %(python2 -c "from distutils.sysconfig import get_python_lib;print(get_python_lib())")}
|
|
| 2 |
+%{!?python3_sitelib: %define python3_sitelib %(python3 -c "from distutils.sysconfig import get_python_lib;print(get_python_lib())")}
|
|
| 2 | 3 |
|
| 3 | 4 |
Name: python-iniparse |
| 4 | 5 |
Version: 0.4 |
| 5 |
-Release: 3%{?dist}
|
|
| 6 |
+Release: 4%{?dist}
|
|
| 6 | 7 |
Summary: Python Module for Accessing and Modifying Configuration Data in INI files |
| 7 | 8 |
Group: Development/Libraries |
| 8 | 9 |
License: MIT |
| 9 | 10 |
URL: http://code.google.com/p/iniparse/ |
| 10 | 11 |
Source0: http://iniparse.googlecode.com/files/iniparse-%{version}.tar.gz
|
| 11 | 12 |
%define sha1 iniparse=2b2af8a19f3e5c212c27d7c524cd748fa0b38650 |
| 12 |
-Vendor: VMware, Inc. |
|
| 13 |
-Distribution: Photon |
|
| 14 |
-BuildRequires: python2-devel |
|
| 15 |
-BuildRequires: python2-libs |
|
| 16 |
-BuildArch: noarch |
|
| 17 |
-Requires: python2 |
|
| 13 |
+Patch0: iniparse-py3-build.patch |
|
| 14 |
+Vendor: VMware, Inc. |
|
| 15 |
+Distribution: Photon |
|
| 16 |
+BuildRequires: python2-devel |
|
| 17 |
+BuildRequires: python2-libs |
|
| 18 |
+BuildArch: noarch |
|
| 19 |
+Requires: python2 |
|
| 18 | 20 |
|
| 19 | 21 |
%description |
| 20 | 22 |
iniparse is an INI parser for Python which is API compatible |
| ... | ... |
@@ -23,19 +25,39 @@ files (order of sections & options, indentation, comments, and blank |
| 23 | 23 |
lines are preserved when data is updated), and is more convenient to |
| 24 | 24 |
use. |
| 25 | 25 |
|
| 26 |
+%package -n python3-iniparse |
|
| 27 |
+Summary: python-iniparse |
|
| 28 |
+BuildRequires: python3 |
|
| 29 |
+BuildRequires: python3-devel |
|
| 30 |
+BuildRequires: python3-libs |
|
| 31 |
+Requires: python3 |
|
| 32 |
+Requires: python3-libs |
|
| 33 |
+Requires: python3-pycparser |
|
| 34 |
+ |
|
| 35 |
+%description -n python3-iniparse |
|
| 36 |
+Python 3 version. |
|
| 37 |
+ |
|
| 26 | 38 |
%prep |
| 27 | 39 |
%setup -q -n iniparse-%{version}
|
| 28 |
- |
|
| 40 |
+%patch0 -p1 |
|
| 41 |
+rm -rf ../p3dir |
|
| 42 |
+cp -a . ../p3dir |
|
| 29 | 43 |
|
| 30 | 44 |
%build |
| 31 |
-%{__python} setup.py build
|
|
| 45 |
+python2 setup.py build |
|
| 46 |
+pushd ../p3dir |
|
| 47 |
+python3 setup.py build |
|
| 48 |
+popd |
|
| 32 | 49 |
|
| 33 | 50 |
%install |
| 34 |
-rm -rf $RPM_BUILD_ROOT |
|
| 35 |
-%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
|
|
| 51 |
+python2 setup.py install --prefix=%{_prefix} --root=%{buildroot}
|
|
| 52 |
+pushd ../p3dir |
|
| 53 |
+python3 setup.py install --prefix=%{_prefix} --root=%{buildroot}
|
|
| 54 |
+popd |
|
| 36 | 55 |
# fixes |
| 37 |
-chmod 644 $RPM_BUILD_ROOT//usr/share/doc/iniparse-%{version}/index.html
|
|
| 38 |
-mv $RPM_BUILD_ROOT/usr/share/doc/iniparse-%{version} $RPM_BUILD_ROOT/usr/share/doc/python-iniparse-%{version}
|
|
| 56 |
+chmod 644 %{buildroot}/usr/share/doc/iniparse-%{version}/index.html
|
|
| 57 |
+mv %{buildroot}/usr/share/doc/iniparse-%{version} %{buildroot}/usr/share/doc/python-iniparse-%{version}
|
|
| 58 |
+ |
|
| 39 | 59 |
|
| 40 | 60 |
%check |
| 41 | 61 |
cp -r iniparse/ tests/ |
| ... | ... |
@@ -47,46 +69,58 @@ python test_ini.py |
| 47 | 47 |
python test_multiprocessing.py |
| 48 | 48 |
python test_unicode.py |
| 49 | 49 |
|
| 50 |
-%clean |
|
| 51 |
-rm -rf $RPM_BUILD_ROOT |
|
| 50 |
+pushd ../p3dir |
|
| 51 |
+cp -r iniparse/ tests/ |
|
| 52 |
+cd tests |
|
| 53 |
+python3 test_misc.py |
|
| 54 |
+python3 test_tidy.py |
|
| 55 |
+python3 test_fuzz.py |
|
| 56 |
+python3 test_ini.py |
|
| 57 |
+python3 test_multiprocessing.py |
|
| 58 |
+python3 test_unicode.py |
|
| 59 |
+popd |
|
| 52 | 60 |
|
| 53 | 61 |
|
| 54 | 62 |
%files |
| 55 | 63 |
%defattr(-,root,root,-) |
| 56 | 64 |
%doc %{_docdir}/python-iniparse-%{version}/*
|
| 57 |
-%{python_sitelib}/iniparse
|
|
| 58 |
-%{python_sitelib}/iniparse-%{version}-py*.egg-info
|
|
| 65 |
+%{python2_sitelib}/*
|
|
| 59 | 66 |
|
| 67 |
+%files -n python3-iniparse |
|
| 68 |
+%defattr(-,root,root,-) |
|
| 69 |
+%{python3_sitelib}/*
|
|
| 60 | 70 |
|
| 61 | 71 |
|
| 62 | 72 |
%changelog |
| 63 |
-* Mon Oct 03 2016 ChangLee <changLee@vmware.com> 0.4-3 |
|
| 64 |
-- Modified %check |
|
| 65 |
-* Tue May 24 2016 Priyesh Padmavilasom <ppadmavilasom@vmware.com> 0.4-2 |
|
| 66 |
-- GA - Bump release of all rpms |
|
| 67 |
-* Sat Jun 12 2010 Paramjit Oberoi <param@cs.wisc.edu> - 0.4-1 |
|
| 68 |
-- Release 0.4 |
|
| 69 |
-* Sat Apr 17 2010 Paramjit Oberoi <param@cs.wisc.edu> - 0.3.2-1 |
|
| 70 |
-- Release 0.3.2 |
|
| 71 |
-* Mon Mar 2 2009 Paramjit Oberoi <param@cs.wisc.edu> - 0.3.1-1 |
|
| 72 |
-- Release 0.3.1 |
|
| 73 |
-* Fri Feb 27 2009 Paramjit Oberoi <param@cs.wisc.edu> - 0.3.0-1 |
|
| 74 |
-- Release 0.3.0 |
|
| 75 |
-* Tue Dec 6 2008 Paramjit Oberoi <param@cs.wisc.edu> - 0.2.4-1 |
|
| 76 |
-- Release 0.2.4 |
|
| 77 |
-- added egg-info file to %%files |
|
| 78 |
-* Tue Dec 11 2007 Paramjit Oberoi <param@cs.wisc.edu> - 0.2.3-1 |
|
| 79 |
-- Release 0.2.3 |
|
| 80 |
-* Tue Sep 24 2007 Paramjit Oberoi <param@cs.wisc.edu> - 0.2.2-1 |
|
| 81 |
-- Release 0.2.2 |
|
| 82 |
-* Tue Aug 7 2007 Paramjit Oberoi <param@cs.wisc.edu> - 0.2.1-1 |
|
| 83 |
-- Release 0.2.1 |
|
| 84 |
-* Fri Jul 27 2007 Tim Lauridsen <timlau@fedoraproject.org> - 0.2-3 |
|
| 85 |
-- relocated doc to %{_docdir}/python-iniparse-%{version}
|
|
| 86 |
-* Thu Jul 26 2007 Tim Lauridsen <timlau@fedoraproject.org> - 0.2-2 |
|
| 87 |
-- changed name from iniparse to python-iniparse |
|
| 88 |
-* Tue Jul 17 2007 Tim Lauridsen <timlau@fedoraproject.org> - 0.2-1 |
|
| 89 |
-- Release 0.2 |
|
| 90 |
-- Added html/* to %%doc |
|
| 91 |
-* Fri Jul 13 2007 Tim Lauridsen <timlau@fedoraproject.org> - 0.1-1 |
|
| 92 |
-- Initial build. |
|
| 73 |
+* Mon May 22 2017 Xiaolin Li <xiaolinl@vmware.com> 0.4-4 |
|
| 74 |
+- Added python3 subpackage. |
|
| 75 |
+* Mon Oct 03 2016 ChangLee <changLee@vmware.com> 0.4-3 |
|
| 76 |
+- Modified %check |
|
| 77 |
+* Tue May 24 2016 Priyesh Padmavilasom <ppadmavilasom@vmware.com> 0.4-2 |
|
| 78 |
+- GA - Bump release of all rpms |
|
| 79 |
+* Sat Jun 12 2010 Paramjit Oberoi <param@cs.wisc.edu> - 0.4-1 |
|
| 80 |
+- Release 0.4 |
|
| 81 |
+* Sat Apr 17 2010 Paramjit Oberoi <param@cs.wisc.edu> - 0.3.2-1 |
|
| 82 |
+- Release 0.3.2 |
|
| 83 |
+* Mon Mar 2 2009 Paramjit Oberoi <param@cs.wisc.edu> - 0.3.1-1 |
|
| 84 |
+- Release 0.3.1 |
|
| 85 |
+* Fri Feb 27 2009 Paramjit Oberoi <param@cs.wisc.edu> - 0.3.0-1 |
|
| 86 |
+- Release 0.3.0 |
|
| 87 |
+* Tue Dec 6 2008 Paramjit Oberoi <param@cs.wisc.edu> - 0.2.4-1 |
|
| 88 |
+- Release 0.2.4 |
|
| 89 |
+- added egg-info file to %%files |
|
| 90 |
+* Tue Dec 11 2007 Paramjit Oberoi <param@cs.wisc.edu> - 0.2.3-1 |
|
| 91 |
+- Release 0.2.3 |
|
| 92 |
+* Tue Sep 24 2007 Paramjit Oberoi <param@cs.wisc.edu> - 0.2.2-1 |
|
| 93 |
+- Release 0.2.2 |
|
| 94 |
+* Tue Aug 7 2007 Paramjit Oberoi <param@cs.wisc.edu> - 0.2.1-1 |
|
| 95 |
+- Release 0.2.1 |
|
| 96 |
+* Fri Jul 27 2007 Tim Lauridsen <timlau@fedoraproject.org> - 0.2-3 |
|
| 97 |
+- relocated doc to %{_docdir}/python-iniparse-%{version}
|
|
| 98 |
+* Thu Jul 26 2007 Tim Lauridsen <timlau@fedoraproject.org> - 0.2-2 |
|
| 99 |
+- changed name from iniparse to python-iniparse |
|
| 100 |
+* Tue Jul 17 2007 Tim Lauridsen <timlau@fedoraproject.org> - 0.2-1 |
|
| 101 |
+- Release 0.2 |
|
| 102 |
+- Added html/* to %%doc |
|
| 103 |
+* Fri Jul 13 2007 Tim Lauridsen <timlau@fedoraproject.org> - 0.1-1 |
|
| 104 |
+- Initial build. |
| 93 | 105 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,41 @@ |
| 0 |
+From 8472bc2706377c93752b2f0b8429b0d18639b65c Mon Sep 17 00:00:00 2001 |
|
| 1 |
+From: Martin Kletzander <mkletzan@redhat.com> |
|
| 2 |
+Date: Fri, 5 Apr 2013 15:12:15 +0200 |
|
| 3 |
+Subject: [PATCH] setup: make build work on python 3 |
|
| 4 |
+ |
|
| 5 |
+In python 3, the string module doesn't have 'split' function anymore |
|
| 6 |
+and users are encouraged to use '.split()' on the string itself. Also |
|
| 7 |
+'map()' is lazy and returns an iterable map object, but setup expects |
|
| 8 |
+only a list, so it has to be wrapped in 'list()'. All of this works |
|
| 9 |
+with python2 as well. |
|
| 10 |
+ |
|
| 11 |
+Signed-off-by: Martin Kletzander <mkletzan@redhat.com> |
|
| 12 |
+--- |
|
| 13 |
+ setup.py | 8 ++++---- |
|
| 14 |
+ 1 file changed, 4 insertions(+), 4 deletions(-) |
|
| 15 |
+ |
|
| 16 |
+diff --git a/setup.py b/setup.py |
|
| 17 |
+index d0d0429..a42a9b7 100644 |
|
| 18 |
+--- a/setup.py |
|
| 19 |
+@@ -1,16 +1,16 @@ |
|
| 20 |
+-import os, string |
|
| 21 |
++import os |
|
| 22 |
+ from distutils.core import setup, Extension |
|
| 23 |
+ |
|
| 24 |
+ pc = os.popen("pkg-config --cflags-only-I glib-2.0 libxml-2.0 sqlite3", "r")
|
|
| 25 |
+-includes = map(lambda x:x[2:], string.split(pc.readline())) |
|
| 26 |
++includes = list(map(lambda x:x[2:], pc.readline().split())) |
|
| 27 |
+ pc.close() |
|
| 28 |
+ |
|
| 29 |
+ pc = os.popen("pkg-config --libs-only-l glib-2.0 libxml-2.0 sqlite3", "r")
|
|
| 30 |
+-libs = map(lambda x:x[2:], string.split(pc.readline())) |
|
| 31 |
++libs = list(map(lambda x:x[2:], pc.readline().split())) |
|
| 32 |
+ pc.close() |
|
| 33 |
+ |
|
| 34 |
+ pc = os.popen("pkg-config --libs-only-L glib-2.0 libxml-2.0 sqlite3", "r")
|
|
| 35 |
+-libdirs = map(lambda x:x[2:], string.split(pc.readline())) |
|
| 36 |
++libdirs = list(map(lambda x:x[2:], pc.readline().split())) |
|
| 37 |
+ pc.close() |
|
| 38 |
+ |
|
| 39 |
+ module = Extension('_sqlitecache',
|
| ... | ... |
@@ -1,52 +1,78 @@ |
| 1 |
-%{!?python_sitelib_platform: %define python_sitelib_platform %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
|
|
| 2 |
- |
|
| 3 |
-Summary: A fast metadata parser for yum |
|
| 4 |
-Name: yum-metadata-parser |
|
| 5 |
-Version: 1.1.4 |
|
| 6 |
-Release: 3%{?dist}
|
|
| 7 |
-Source0: %{name}-%{version}.tar.gz
|
|
| 8 |
-%define sha1 yum-metadata-parser=044e69a04ea5ac39d79020d9e1f1a35c9dc64d9b |
|
| 9 |
-License: GPLv2+ |
|
| 10 |
-Group: Development/Libraries |
|
| 11 |
-URL: http://devel.linux.duke.edu/cgi-bin/viewcvs.cgi/yum-metadata-parser/ |
|
| 12 |
-Vendor: VMware, Inc. |
|
| 13 |
-Distribution: Photon |
|
| 14 |
-BuildRequires: pkg-config |
|
| 15 |
-BuildRequires: python2-devel |
|
| 16 |
-BuildRequires: glib-devel |
|
| 17 |
-BuildRequires: libxml2 |
|
| 18 |
-BuildRequires: libxml2-devel |
|
| 19 |
-BuildRequires: sqlite-devel |
|
| 20 |
-BuildRequires: python2-libs |
|
| 21 |
-Requires: libxml2 |
|
| 22 |
-Requires: glib |
|
| 23 |
-Requires: python2 |
|
| 1 |
+%{!?python2_sitelib: %define python2_sitelib %(python2 -c "from distutils.sysconfig import get_python_lib;print(get_python_lib())")}
|
|
| 2 |
+%{!?python3_sitelib: %define python3_sitelib %(python3 -c "from distutils.sysconfig import get_python_lib;print(get_python_lib())")}
|
|
| 3 |
+ |
|
| 4 |
+Summary: A fast metadata parser for yum |
|
| 5 |
+Name: yum-metadata-parser |
|
| 6 |
+Version: 1.1.4 |
|
| 7 |
+Release: 4%{?dist}
|
|
| 8 |
+License: GPLv2+ |
|
| 9 |
+Group: Development/Libraries |
|
| 10 |
+URL: http://devel.linux.duke.edu/cgi-bin/viewcvs.cgi/yum-metadata-parser/ |
|
| 11 |
+Vendor: VMware, Inc. |
|
| 12 |
+Distribution: Photon |
|
| 13 |
+Source0: %{name}-%{version}.tar.gz
|
|
| 14 |
+%define sha1 yum-metadata-parser=044e69a04ea5ac39d79020d9e1f1a35c9dc64d9b |
|
| 15 |
+Patch0: Upstream-py3-string-split.patch |
|
| 16 |
+BuildRequires: pkg-config |
|
| 17 |
+BuildRequires: python2-devel |
|
| 18 |
+BuildRequires: glib-devel |
|
| 19 |
+BuildRequires: libxml2 |
|
| 20 |
+BuildRequires: libxml2-devel |
|
| 21 |
+BuildRequires: sqlite-devel |
|
| 22 |
+BuildRequires: python2-libs |
|
| 23 |
+Requires: libxml2 |
|
| 24 |
+Requires: glib |
|
| 25 |
+Requires: python2 |
|
| 24 | 26 |
%description |
| 25 | 27 |
Fast metadata parser for yum implemented in C. |
| 26 | 28 |
|
| 29 |
+%package -n python3-yum-metadata-parser |
|
| 30 |
+Summary: python3-yum-metadata-parser |
|
| 31 |
+BuildRequires: python3 |
|
| 32 |
+BuildRequires: python3-devel |
|
| 33 |
+BuildRequires: python3-libs |
|
| 34 |
+Requires: python3 |
|
| 35 |
+Requires: python3-libs |
|
| 36 |
+Requires: libxml2 |
|
| 37 |
+Requires: glib |
|
| 38 |
+ |
|
| 39 |
+%description -n python3-yum-metadata-parser |
|
| 40 |
+ |
|
| 27 | 41 |
%prep |
| 28 | 42 |
%setup |
| 43 |
+%patch0 -p1 |
|
| 44 |
+rm -rf ../p3dir |
|
| 45 |
+cp -a . ../p3dir |
|
| 29 | 46 |
|
| 30 | 47 |
%build |
| 31 |
-%{__python} setup.py build
|
|
| 48 |
+python2 setup.py build |
|
| 49 |
+pushd ../p3dir |
|
| 50 |
+python3 setup.py build |
|
| 51 |
+popd |
|
| 32 | 52 |
|
| 33 | 53 |
%install |
| 34 |
-%{__python} setup.py install -O1 --root=%{buildroot}
|
|
| 35 |
- |
|
| 36 |
-%clean |
|
| 37 |
-%{__rm} -rf %{buildroot}
|
|
| 54 |
+python2 setup.py install -O1 --root=%{buildroot}
|
|
| 55 |
+pushd ../p3dir |
|
| 56 |
+python3 setup.py install -O1 --root=%{buildroot}
|
|
| 57 |
+popd |
|
| 38 | 58 |
|
| 39 | 59 |
%files |
| 40 | 60 |
%defattr(-,root,root) |
| 41 | 61 |
%doc README AUTHORS ChangeLog |
| 42 |
-%{python_sitelib_platform}/_sqlitecache.so
|
|
| 43 |
-%{python_sitelib_platform}/sqlitecachec.py
|
|
| 44 |
-%{python_sitelib_platform}/sqlitecachec.pyc
|
|
| 45 |
-%{python_sitelib_platform}/sqlitecachec.pyo
|
|
| 46 |
-%{python_sitelib_platform}/*egg-info
|
|
| 62 |
+%{python2_sitelib}/_sqlitecache.so
|
|
| 63 |
+%{python2_sitelib}/sqlitecachec.py
|
|
| 64 |
+%{python2_sitelib}/sqlitecachec.pyc
|
|
| 65 |
+%{python2_sitelib}/sqlitecachec.pyo
|
|
| 66 |
+%{python2_sitelib}/*egg-info
|
|
| 67 |
+ |
|
| 68 |
+%files -n python3-yum-metadata-parser |
|
| 69 |
+%defattr(-,root,root) |
|
| 70 |
+%{python3_sitelib}/*
|
|
| 47 | 71 |
|
| 48 | 72 |
%changelog |
| 73 |
+* Thu May 18 2017 Xiaolin Li <xiaolinl@vmware.com> 1.1.4-4 |
|
| 74 |
+- Added python3 site-packages. |
|
| 49 | 75 |
* Wed Nov 16 2016 Alexey Makhalov <ppadmavilasom@vmware.com> 1.1.4-3 |
| 50 | 76 |
- Use sqlite-{devel,libs}
|
| 51 | 77 |
* Tue May 24 2016 Priyesh Padmavilasom <ppadmavilasom@vmware.com> 1.1.4-2 |
| 52 |
-- GA - Bump release of all rpms |
|
| 78 |
+- GA - Bump release of all rpms |
|
| 53 | 79 |
\ No newline at end of file |