| |
@@ -1,6 +1,11 @@
|
| |
+ %if 0%{?fedora}
|
| |
+ # Not all python modules are built with Python3 in EPEL
|
| |
+ %global with_python3 1
|
| |
+ %endif
|
| |
+
|
| |
Name: module-build-service
|
| |
Version: 2.0.2
|
| |
- Release: 3%{?dist}
|
| |
+ Release: 4%{?dist}
|
| |
Summary: The Module Build Service for Modularity
|
| |
|
| |
Group: Development/Tools
|
| |
@@ -16,32 +21,47 @@
|
| |
ExclusiveArch: %{ix86} x86_64 noarch
|
| |
%endif
|
| |
|
| |
+ %if 0%{?with_python3}
|
| |
+
|
| |
+ BuildRequires: python3-devel
|
| |
+ BuildRequires: python3-setuptools
|
| |
+ BuildRequires: python3-m2crypto
|
| |
+ BuildRequires: python3-mock
|
| |
+ BuildRequires: python3-pdc-client
|
| |
+ BuildRequires: python3-flask-script
|
| |
+ BuildRequires: python3-munch
|
| |
+ BuildRequires: python3-funcsigs
|
| |
+ BuildRequires: python3-solv
|
| |
+ BuildRequires: python3-gobject-base
|
| |
+ BuildRequires: python3-openidc-client
|
| |
+ BuildRequires: python3-ldap3
|
| |
+ BuildRequires: python3-koji
|
| |
+ BuildRequires: python3-setuptools
|
| |
+ BuildRequires: python3-flask-sqlalchemy
|
| |
+ BuildRequires: python3-flask-migrate
|
| |
+ BuildRequires: python3-six
|
| |
+ BuildRequires: python3-flask
|
| |
+ BuildRequires: python3-dogpile-cache
|
| |
+ BuildRequires: python3-requests
|
| |
+ BuildRequires: python3-pyOpenSSL
|
| |
+ BuildRequires: python3-sqlalchemy
|
| |
+
|
| |
+ %else
|
| |
+
|
| |
BuildRequires: python2-devel
|
| |
|
| |
BuildRequires: python2-mock
|
| |
- BuildRequires: fedmsg
|
| |
- BuildRequires: git
|
| |
- BuildRequires: help2man
|
| |
- BuildRequires: kobo
|
| |
- BuildRequires: kobo-rpmlib
|
| |
-
|
| |
BuildRequires: m2crypto
|
| |
- BuildRequires: mock
|
| |
BuildRequires: python2-pdc-client
|
| |
BuildRequires: python-flask-script
|
| |
BuildRequires: python-m2ext
|
| |
BuildRequires: python-munch
|
| |
BuildRequires: python2-funcsigs
|
| |
- BuildRequires: libmodulemd
|
| |
BuildRequires: python2-solv
|
| |
- BuildRequires: gobject-introspection
|
| |
BuildRequires: python-gobject-base
|
| |
- BuildRequires: rpm-build
|
| |
- BuildRequires: python-qpid
|
| |
BuildRequires: python-openidc-client
|
| |
BuildRequires: python-ldap3
|
| |
BuildRequires: python-enum34
|
| |
-
|
| |
BuildRequires: python2-koji
|
| |
|
| |
%if 0%{?rhel} && 0%{?rhel} <= 7
|
| |
@@ -71,43 +91,54 @@
|
| |
BuildRequires: python2-sqlalchemy
|
| |
%endif
|
| |
|
| |
- BuildRequires: systemd
|
| |
+ %endif
|
| |
|
| |
- Requires: systemd
|
| |
- Requires: fedmsg
|
| |
- Requires: fedpkg
|
| |
- Requires: git
|
| |
- Requires: kobo
|
| |
- Requires: kobo-rpmlib
|
| |
- Requires: m2crypto
|
| |
- Requires: mock
|
| |
+ BuildRequires: fedmsg
|
| |
+ BuildRequires: git-core
|
| |
+ BuildRequires: help2man
|
| |
+ BuildRequires: kobo
|
| |
+ BuildRequires: kobo-rpmlib
|
| |
+ BuildRequires: mock
|
| |
+ BuildRequires: libmodulemd
|
| |
+ BuildRequires: gobject-introspection
|
| |
+ BuildRequires: rpm-build
|
| |
+
|
| |
+ %if 0%{?with_python3}
|
| |
+ Requires: python3-pdc-client
|
| |
+ Requires: python3-flask-script
|
| |
+ Requires: python3-munch
|
| |
+ Requires: python3-funcsigs
|
| |
+ Requires: python3-openidc-client
|
| |
+ Requires: python3-ldap3
|
| |
+ Requires: python3-gobject-base
|
| |
+ Requires: python3-solv
|
| |
+ Requires: python3-koji
|
| |
+ Requires: python3-flask-sqlalchemy
|
| |
+ Requires: python3-flask-migrate
|
| |
+ Requires: python3-mock
|
| |
+ Requires: python3-six
|
| |
+
|
| |
+ Requires: python3-sqlalchemy
|
| |
+ Requires: python3-flask
|
| |
+ Requires: python3-dogpile-cache
|
| |
+ Requires: python3-requests
|
| |
+ %else
|
| |
Requires: python2-pdc-client
|
| |
- Requires: pyOpenSSL
|
| |
Requires: python-flask-script
|
| |
- Requires: python-m2ext
|
| |
Requires: python-munch
|
| |
Requires: python2-funcsigs
|
| |
- Requires: libmodulemd
|
| |
- Requires: rpm-build
|
| |
- Requires: python-qpid
|
| |
Requires: python-enum34
|
| |
Requires: python-openidc-client
|
| |
Requires: python-ldap3
|
| |
- Requires: gobject-introspection
|
| |
Requires: python-gobject-base
|
| |
Requires: python2-solv
|
| |
-
|
| |
Requires: python2-koji
|
| |
|
| |
- # https://bugzilla.redhat.com/show_bug.cgi?id=1466792
|
| |
- Requires: mock-scm
|
| |
-
|
| |
%if 0%{?rhel} && 0%{?rhel} <= 7
|
| |
Requires: python-flask-sqlalchemy
|
| |
Requires: python-flask-migrate
|
| |
Requires: python-mock
|
| |
Requires: python-six
|
| |
- Requires: pyOpenSSL
|
| |
Requires: python-sqlalchemy
|
| |
Requires: python-futures
|
| |
Requires: python-flask
|
| |
@@ -127,6 +158,22 @@
|
| |
Requires: python2-sqlalchemy
|
| |
%endif
|
| |
|
| |
+ %endif
|
| |
+
|
| |
+ Requires: fedmsg
|
| |
+ Requires: fedpkg
|
| |
+ Requires: git-core
|
| |
+ Requires: kobo
|
| |
+ Requires: kobo-rpmlib
|
| |
+ Requires: m2crypto
|
| |
+ Requires: mock
|
| |
+ Requires: pyOpenSSL
|
| |
+ Requires: libmodulemd
|
| |
+ Requires: rpm-build
|
| |
+ Requires: gobject-introspection
|
| |
+ # https://bugzilla.redhat.com/show_bug.cgi?id=1466792
|
| |
+ Requires: mock-scm
|
| |
+
|
| |
|
| |
%description
|
| |
The Module Build Service (MBS) coordinates module builds and is responsible
|
| |
@@ -158,13 +205,27 @@
|
| |
rm -f module_build_service/.mbs_local_build.db
|
| |
|
| |
%build
|
| |
+ %if 0%{?with_python3}
|
| |
+ %py3_build
|
| |
+ %else
|
| |
%py2_build
|
| |
+ %endif
|
| |
+
|
| |
|
| |
%install
|
| |
+ %if 0%{?with_python3}
|
| |
+ %py3_install
|
| |
+ %else
|
| |
%py2_install
|
| |
+ %endif
|
| |
|
| |
%if 0%{?with_epel}
|
| |
+
|
| |
+ %if 0%{?with_python3}
|
| |
+ export PYTHONPATH=%{buildroot}%{python3_sitelib}
|
| |
+ %else
|
| |
export PYTHONPATH=%{buildroot}%{python2_sitelib}
|
| |
+ %endif
|
| |
mkdir -p %{buildroot}/%{_mandir}/man1
|
| |
for command in mbs-manager mbs-frontend mbs-upgradedb ; do
|
| |
MBS_CONFIG_FILE=conf/config.py %{buildroot}/%{_bindir}/$command --help || true
|
| |
@@ -183,7 +244,13 @@
|
| |
%files
|
| |
%doc README.rst
|
| |
%license LICENSE
|
| |
+
|
| |
+ %if 0%{?with_python3}
|
| |
+ %{python3_sitelib}/module_build_service*
|
| |
+ %else
|
| |
%{python2_sitelib}/module_build_service*
|
| |
+ %endif
|
| |
+
|
| |
%{_bindir}/mbs-*
|
| |
%dir %{_sysconfdir}/module-build-service
|
| |
%config(noreplace) %{_sysconfdir}/module-build-service/config.py
|
| |
@@ -197,8 +264,14 @@
|
| |
%config(noreplace) %{_sysconfdir}/fedmsg.d/module_build_service.py
|
| |
%exclude %{_sysconfdir}/module-build-service/*.py[co]
|
| |
%exclude %{_sysconfdir}/fedmsg.d/*.py[co]
|
| |
+
|
| |
+ %if 0%{?with_python3}
|
| |
+ %exclude %{python3_sitelib}/conf/
|
| |
+ %exclude %{python3_sitelib}/tests/
|
| |
+ %else
|
| |
%exclude %{python2_sitelib}/conf/
|
| |
%exclude %{python2_sitelib}/tests/
|
| |
+ %endif
|
| |
|
| |
%if 0%{?with_epel}
|
| |
%{_mandir}/man1/mbs-*.1*
|
| |
@@ -206,6 +279,9 @@
|
| |
|
| |
|
| |
%changelog
|
| |
+ * Tue Apr 17 2018 Jan Kaluza <jkaluza@redhat.com> - 2.0.2-4
|
| |
+ - use python3 by default
|
| |
+
|
| |
* Thu Apr 05 2018 Jan Kaluza <jkaluza@redhat.com> - 2.0.2-3
|
| |
- fix wrong component reuse caused by missing change for buildrequires.
|
| |
|
| |