X-Git-Url: http://git.pld-linux.org/?a=blobdiff_plain;f=bzr.spec;h=faf35ff99b5fb380366a385892d4d1738114f4a5;hb=HEAD;hp=ecedb807ac26db304c10556d30f9ba4456fffb0f;hpb=a47ebf9838de641e0236266a50929a9a2d6c05bd;p=packages%2Fbzr.git diff --git a/bzr.spec b/bzr.spec index ecedb80..faf35ff 100644 --- a/bzr.spec +++ b/bzr.spec @@ -1,25 +1,28 @@ +# TODO: python3 when supported upstream (currently it uses cobjects, whith don't exist in python 3.2+) + Summary: Bazaar - a distributed revision control system Summary(pl.UTF-8): Bazaar - rozproszony system kontroli wersji Name: bzr -%define ver 1.10 -# define minor %{nil} -Version: %{ver}%{?minor:.%{minor}} +Version: 2.7.0 Release: 1 -License: GPL v2 +License: GPL v2+ Group: Development/Version Control -Source0: https://launchpad.net/bzr/%{ver}/%{version}/+download/%{name}-%{version}%{?minor:.%{minor}}.tar.gz -# Source0-md5: 1b31db46601efa8812c4d545a7069f82 -URL: http://bazaar-vcs.org/ -BuildRequires: python >= 1:2.5 +#Source0Download: https://launchpad.net/bzr/+download +Source0: https://launchpad.net/bzr/2.7/%{version}/+download/%{name}-%{version}.tar.gz +# Source0-md5: 8e5020502efd54f5925a14a456b88b89 +Patch0: locale-path.patch +Patch1: ca-certificates.patch +URL: http://bazaar.canonical.com/ +BuildRequires: python >= 1:2.6 +BuildRequires: python-devel >= 1:2.6 +BuildRequires: rpm-build >= 4.6 BuildRequires: rpm-pythonprov -BuildRequires: rpmbuild(macros) >= 1.219 -%pyrequires_eq python -# pdb module required by bzr -Requires: python-devel-tools -Requires: python-cElementTree -Requires: python-paramiko -Requires: python-pycurl -Obsoletes: bazaar +BuildRequires: rpmbuild(macros) >= 1.714 +BuildRequires: zlib-devel +Requires: python >= 1:2.6 +Requires: python-bzr = %{version}-%{release} +Obsoletes: bazaar < 1.5 +Conflicts: qbzr < 0.22 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) %description @@ -63,29 +66,120 @@ Dodatkowe możliwości takie jak: cherry picking, obsługa innych systemów kontroli wersji, GUI są dostępne poprzez dodatkowe pakiety rozszerzeń. +%package -n python-bzr +Summary: Bazaar library for Python 2 +Summary(pl.UTF-8): Biblioteka Bazaar dla Pythona 2 +Group: Libraries/Python +# pdb module required by bzr +Requires: python-devel-tools >= 1:2.6 +Requires: python-paramiko +Requires: python-pycurl + +%description -n python-bzr +Bazaar is a friendly distributed version control system. + +This package contains Python 2 library. + +%description -n python-bzr -l pl.UTF-8 +Bazaar to przyjazny, rozproszony system kontroli wersji. + +Ten pakiet zawiera bibliotekę Pythona 2. + +%package -n bash-completion-%{name} +Summary: bash-completion for bzr +Group: Applications/Shells +Requires: %{name} = %{version}-%{release} +Requires: bash-completion +BuildArch: noarch + +%description -n bash-completion-%{name} +This package provides bash-completion for bzr. + %prep %setup -q +%patch0 -p1 +%patch1 -p1 + +# move out of contrib, as we package contrib as doc +%{__mv} contrib/bash/bzr bash_completion.sh %build -%{__python} setup.py build +%py_build + +%if 0 +%py3_build +%endif %install rm -rf $RPM_BUILD_ROOT -%{__python} setup.py install \ - --optimize=2 \ - --install-data %{_datadir} \ - --root=$RPM_BUILD_ROOT +%if 0 +%py3_install \ + --install-data %{_datadir} +%endif + +%py_install \ + --install-data %{_datadir} %py_postclean +# bash-completion +install -d $RPM_BUILD_ROOT/etc/bash_completion.d +install -p bash_completion.sh $RPM_BUILD_ROOT/etc/bash_completion.d/%{name} + +# don't package tests +%{__rm} -r $RPM_BUILD_ROOT%{py_sitedir}/bzrlib/plugins/bash_completion/tests +%{__rm} -r $RPM_BUILD_ROOT%{py_sitedir}/bzrlib/plugins/launchpad/test_*.py* +%{__rm} -r $RPM_BUILD_ROOT%{py_sitedir}/bzrlib/plugins/netrc_credential_store/tests +%{__rm} -r $RPM_BUILD_ROOT%{py_sitedir}/bzrlib/plugins/news_merge/tests +%{__rm} -r $RPM_BUILD_ROOT%{py_sitedir}/bzrlib/tests +%{__rm} -r $RPM_BUILD_ROOT%{py_sitedir}/bzrlib/util/tests + +%if 0 +%{__rm} -r $RPM_BUILD_ROOT%{py3_sitedir}/bzrlib/plugins/bash_completion/tests +%{__rm} -r $RPM_BUILD_ROOT%{py3_sitedir}/bzrlib/plugins/launchpad/test_*.py* +%{__rm} -r $RPM_BUILD_ROOT%{py3_sitedir}/bzrlib/plugins/netrc_credential_store/tests +%{__rm} -r $RPM_BUILD_ROOT%{py3_sitedir}/bzrlib/plugins/news_merge/tests +%{__rm} -r $RPM_BUILD_ROOT%{py3_sitedir}/bzrlib/tests +%{__rm} -r $RPM_BUILD_ROOT%{py3_sitedir}/bzrlib/util/tests +%endif + +# sco locale is not supported by glibc +%{__rm} -r $RPM_BUILD_ROOT%{_localedir}/sco + +%find_lang %{name} + %clean rm -rf $RPM_BUILD_ROOT -%files +%files -f %{name}.lang %defattr(644,root,root,755) -%doc doc/*.txt NEWS README TODO -%attr(755,root,root) %{_bindir}/* +%doc doc/*.txt NEWS README TODO contrib +%attr(755,root,root) %{_bindir}/bzr %{_mandir}/man1/bzr.1* -%{py_sitedir}/bzrlib -%{py_sitedir}/*.egg-info + +%files -n python-bzr +%defattr(644,root,root,755) +%dir %{py_sitedir}/bzrlib +%{py_sitedir}/bzrlib/*.py[co] +%attr(755,root,root) %{py_sitedir}/bzrlib/_*.so +%{py_sitedir}/bzrlib/bundle +%{py_sitedir}/bzrlib/branchfmt +%{py_sitedir}/bzrlib/doc +%{py_sitedir}/bzrlib/doc_generate +%{py_sitedir}/bzrlib/export +%{py_sitedir}/bzrlib/filters +%{py_sitedir}/bzrlib/help_topics +%{py_sitedir}/bzrlib/plugins +%{py_sitedir}/bzrlib/repofmt +%{py_sitedir}/bzrlib/smart +%{py_sitedir}/bzrlib/store +%{py_sitedir}/bzrlib/transport +%{py_sitedir}/bzrlib/ui +%{py_sitedir}/bzrlib/util +%{py_sitedir}/bzrlib/version_info_formats +%{py_sitedir}/bzr-%{version}-py*.egg-info + +%files -n bash-completion-%{name} +%defattr(644,root,root,755) +/etc/bash_completion.d/%{name}