#1245 organize python 2/3 cases in spec file
Merged 5 years ago by mikem. Opened 5 years ago by mikem.
mikem/koji py23macros  into  master

file modified
+158 -70
@@ -1,17 +1,57 @@ 

- # Enable Python 3 builds for Fedora/RHEL8

- %if 0%{?fedora} || 0%{?rhel} >= 8

  %bcond_without python3

- # If the definition isn't available for python3_pkgversion, define it

- %{?!python3_pkgversion:%global python3_pkgversion 3}

+ %bcond_without python2

+ %global _python_bytecompile_extra 0

+ 

+ # We can build varying amounts of Koji for python2 and python3 based on

+ # the py[23]_support macro values. Valid values are:

+ #   undefined or 0 -- do not build

+ #   1 -- build just the cli and lib

+ #   2 -- build everything we can

+ # For executable scripts, py3 wins if we build it

+ # The following rules tweak these settings based on options and environment

+ 

+ # Default to building both fully

+ %define py2_support 2

+ %define py3_support 2

+ 

+ %if 0%{?rhel} >= 8

+ # and no python2 on rhel8+

+ %define py2_support 0

  %else

- %bcond_with python3

+ %if 0%{?rhel}

+ # No python3 for older rhel

+ %define py3_support 0

+ %endif

  %endif

  

- # don't build py2 packages for py3-only systems

- %if 0%{with python3} && (0%{?fedora} > 32 || 0%{?rhel} > 7)

-     %define with_python2 0

+ %if 0%{?fedora} >= 33

+ # no py2 after F33

+ %define py2_support 0

+ %define py3_support 2

  %else

-     %define with_python2 1

+ %if 0%{?fedora} >= 30

+ %define py2_support 1

+ %define py3_support 2

+ %else

+ %if 0%{?fedora}

+ # match what the older Fedoras already have

+ %define py2_support 2

+ %define py3_support 1

+ %endif

+ %endif

+ %endif

+ 

+ # Lastly enforce the bcond parameters

+ %if %{without python2}

+ %define py2_support 0

+ %endif

+ %if %{without python3}

+ %define py3_support 0

+ %endif

+ 

+ %if ! %{py2_support}

+ # use python3

+ %define __python %{__python3}

  %endif

  

  # Compatibility with RHEL. These macros have been added to EPEL but
@@ -23,6 +63,9 @@ 

  %{!?py2_build: %global py2_build %{expand: CFLAGS="%{optflags}" %{__python2} setup.py %{?py_setup_args} build --executable="%{__python2} -s"}}

  %{!?py2_install: %global py2_install %{expand: CFLAGS="%{optflags}" %{__python2} setup.py %{?py_setup_args} install -O1 --skip-build --root %{buildroot}}}

  

+ # If the definition isn't available for python3_pkgversion, define it

+ %{?!python3_pkgversion:%global python3_pkgversion 3}

+ 

  %if 0%{?fedora} >= 21 || 0%{?rhel} >= 7

  %global use_systemd 1

  %else
@@ -48,7 +91,7 @@ 

  Source: https://releases.pagure.org/koji/koji-%{version}.tar.bz2

  BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

  BuildArch: noarch

- %if 0%{with python3}

+ %if 0%{py3_support}

  Requires: python%{python3_pkgversion}-%{name} = %{version}-%{release}

  Requires: python%{python3_pkgversion}-libcomps

  %else
@@ -66,7 +109,7 @@ 

  Koji is a system for building and tracking RPMS.  The base package

  contains shared libraries and the command-line interface.

  

- %if 0%{with_python2}

+ %if 0%{py2_support}

  %package -n python2-%{name}

  Summary: Build system tools python library

  %{?python_provide:%python_provide python2-%{name}}
@@ -90,7 +133,7 @@ 

  desc

  %endif

  

- %if 0%{with python3}

+ %if 0%{py3_support}

  %package -n python%{python3_pkgversion}-%{name}

  Summary: Build system tools python library

  %{?python_provide:%python_provide python%{python3_pkgversion}-%{name}}
@@ -110,23 +153,23 @@ 

  desc

  %endif

  

- %if 0%{with_python2}

+ %if 0%{py2_support}

  %package -n python2-%{name}-cli-plugins

  Summary: Koji client plugins

  Group: Applications/Internet

  License: LGPLv2

- Requires: %{name} = %{version}-%{release}

+ Requires: python2-%{name} = %{version}-%{release}

  

  %description -n python2-%{name}-cli-plugins

  Plugins to the koji command-line interface

  %endif

  

- %if 0%{with python3}

+ %if 0%{py3_support}

  %package -n python%{python3_pkgversion}-%{name}-cli-plugins

  Summary: Koji client plugins

  Group: Applications/Internet

  License: LGPLv2

- Requires: %{name} = %{version}-%{release}

+ Requires: python%{python3_pkgversion}-%{name} = %{version}-%{release}

  

  %description -n python%{python3_pkgversion}-%{name}-cli-plugins

  Plugins to the koji command-line interface
@@ -146,6 +189,7 @@ 

  %description hub

  koji-hub is the XMLRPC interface to the koji database

  

+ %if 0%{py2_support} > 1

  %package -n python2-%{name}-hub

  Summary: Koji XMLRPC interface

  Group: Applications/Internet
@@ -157,16 +201,15 @@ 

  Requires: mod_auth_gssapi

  %endif

  Requires: python-psycopg2

- Requires: %{name} = %{version}-%{release}

- # we need the python2 lib here

  Requires: python2-%{name} = %{version}-%{release}

  # py2 xor py3

  Provides: %{name}-hub-code = %{version}-%{release}

  

  %description -n python2-%{name}-hub

  koji-hub is the XMLRPC interface to the koji database

+ %endif

  

- %if 0%{with python3}

+ %if 0%{py3_support} > 1

  %package -n python%{python3_pkgversion}-%{name}-hub

  Summary: Koji XMLRPC interface

  Group: Applications/Internet
@@ -178,8 +221,6 @@ 

  Requires: mod_auth_gssapi

  %endif

  Requires: python-psycopg2

- Requires: %{name} = %{version}-%{release}

- # we need the python2 lib here

  Requires: python%{python3_pkgversion}-%{name} = %{version}-%{release}

  # py2 xor py3

  Provides: %{name}-hub-code = %{version}-%{release}
@@ -192,7 +233,7 @@ 

  Summary: Koji hub plugins

  Group: Applications/Internet

  License: LGPLv2

- Requires: %{name}-hub-plugins-code

+ Requires: %{name}-hub-plugins-code = %{version}-%{release}

  %if 0%{?fedora} || 0%{?rhel} > 7

  Suggests: python%{python3_pkgversion}-%{name}-hub-plugins

  %endif
@@ -200,33 +241,29 @@ 

  %description hub-plugins

  Plugins to the koji XMLRPC interface

  

+ %if 0%{py2_support} > 1

  %package -n python2-%{name}-hub-plugins

  Summary: Koji hub plugins

  Group: Applications/Internet

  License: LGPLv2

  Requires: python2-%{name}-hub = %{version}-%{release}

- Requires: python-qpid >= 0.7

- %if 0%{?fedora} >= 27 || 0%{?rhel} >= 6

- Requires: python-qpid-proton

- %endif

+ Requires: python2-qpid-proton

  Requires: cpio

- Provides: %{name}-hub-plugins-code

+ Provides: %{name}-hub-plugins-code = %{version}-%{release}

  

  %description -n python2-%{name}-hub-plugins

  Plugins to the koji XMLRPC interface

+ %endif

  

- %if 0%{with python3}

+ %if 0%{py3_support} > 1

  %package -n python%{python3_pkgversion}-%{name}-hub-plugins

  Summary: Koji hub plugins

  Group: Applications/Internet

  License: LGPLv2

  Requires: python%{python3_pkgversion}-%{name}-hub = %{version}-%{release}

- Requires: python-qpid >= 0.7

- %if 0%{?fedora} >= 27 ||  0%{?rhel} >= 6

  Requires: python%{python3_pkgversion}-qpid-proton

- %endif

  Requires: cpio

- Provides: %{name}-hub-plugins-code

+ Provides: %{name}-hub-plugins-code = %{version}-%{release}

  

  %description -n python%{python3_pkgversion}-%{name}-hub-plugins

  Plugins to the koji XMLRPC interface
@@ -264,7 +301,7 @@ 

  Requires: /usr/bin/svn

  Requires: /usr/bin/git

  Requires: createrepo >= 0.9.2

- %if 0%{with python3}

+ %if 0%{py3_support} > 1

  Requires: python%{python3_pkgversion}-%{name} = %{version}-%{release}

  Requires: python%{python3_pkgversion}-multilib

  Requires: python%{python3_pkgversion}-cheetah
@@ -308,8 +345,6 @@ 

  Group: Applications/Internet

  License: LGPLv2

  Requires: python-psycopg2

- Requires: %{name} = %{version}-%{release}

- # we need the python2 lib here

  Requires: python2-%{name} = %{version}-%{release}

  %if %{use_systemd}

  Requires(post): systemd
@@ -320,7 +355,20 @@ 

  %description utils

  Utilities for the Koji system

  

- %if 0%{with_python2}

+ %package web

+ Summary: Koji Web UI

+ Group: Applications/Internet

+ License: LGPLv2

+ Requires: %{name} = %{version}-%{release}

+ Requires: %{name}-web-code = %{version}-%{release}

+ %if 0%{?fedora} || 0%{?rhel} > 7

+ Suggests: python%{python3_pkgversion}-%{name}-web

+ %endif

+ 

+ %description web

+ koji-web is a web UI to the Koji system.

+ 

+ %if 0%{py2_support} > 1

  %package -n python2-%{name}-web

  Summary: Koji Web UI

  Group: Applications/Internet
@@ -337,14 +385,13 @@ 

  Requires: python-psycopg2

  Requires: python-cheetah

  Requires: python2-%{name} = %{version}-%{release}

- Provides: koji-web = %{version}-%{release}

- Obsoletes: koji-web < 1.16.2

+ Provides: %{name}-web-code = %{version}-%{release}

  

  %description -n python2-%{name}-web

  koji-web is a web UI to the Koji system.

  %endif

  

- %if 0%{with python3}

+ %if 0%{py3_support} > 1

  %package -n python%{python3_pkgversion}-%{name}-web

  Summary: Koji Web UI

  Group: Applications/Internet
@@ -356,8 +403,7 @@ 

  Requires: python%{python3_pkgversion}-psycopg2

  Requires: python%{python3_pkgversion}-cheetah

  Requires: python%{python3_pkgversion}-%{name} = %{version}-%{release}

- Provides: koji-web = %{version}-%{release}

- Obsoletes: koji-web < 1.16.2

+ Provides: %{name}-web-code = %{version}-%{release}

  

  %description -n python%{python3_pkgversion}-%{name}-web

  koji-web is a web UI to the Koji system.
@@ -370,18 +416,66 @@ 

  

  %install

  rm -rf $RPM_BUILD_ROOT

- %if 0%{with_python2}

+ 

+ %if 0%{py2_support} < 2  &&  0%{py3_support} < 2

+ echo "At least one python must be built with full support"

+ exit 1

+ %endif

+ 

+ # python2 build

+ %if 0%{py2_support} > 1

  make DESTDIR=$RPM_BUILD_ROOT PYTHON=%{__python2} %{?install_opt} install

+ %else

+ %if 0%{py2_support}

+ for d in koji cli plugins ; do

+     pushd $d

+     make DESTDIR=$RPM_BUILD_ROOT KOJI_MINIMAL=1 PYTHON=%{__python2} %{?install_opt} install

+     popd

+ done

  %endif

- %if 0%{with python3}

- for d in koji cli plugins hub www ; do

+ %endif

+ 

+ 

+ # python3 build

+ %if 0%{py3_support} > 1

+ make DESTDIR=$RPM_BUILD_ROOT PYTHON=%{__python3} %{?install_opt} install

+ # alter python interpreter in koji CLI

+ scripts='%{_bindir}/koji %{_sbindir}/kojid %{_sbindir}/kojira %{_sbindir}/koji-shadow

+          %{_sbindir}/koji-gc %{_sbindir}/kojivmd'

+ for fn in $scripts ; do

+     sed -i 's|#!/usr/bin/python2|#!/usr/bin/python3|' $RPM_BUILD_ROOT$fn

+ done

+ %else

+ %if 0%{py3_support}

+ # minimal

+ for d in koji cli plugins ; do

      pushd $d

-     make DESTDIR=$RPM_BUILD_ROOT PYTHON=%{__python3} %{?install_opt} install

+     make DESTDIR=$RPM_BUILD_ROOT KOJI_MINIMAL=1 PYTHON=%{__python3} %{?install_opt} install

      popd

  done

  # alter python interpreter in koji CLI

- sed -i 's/\#\!\/usr\/bin\/python2/\#\!\/usr\/bin\/python3/' $RPM_BUILD_ROOT/usr/bin/koji

- sed -i 's/\#\!\/usr\/bin\/python2/\#\!\/usr\/bin\/python3/' $RPM_BUILD_ROOT/usr/sbin/kojid

+ sed -i 's|#!/usr/bin/python2|#!/usr/bin/python3|' $RPM_BUILD_ROOT/usr/bin/koji

+ %endif

+ %endif

+ 

+ %if 0%{?fedora} >= 28

+ # handle extra byte compilation

+ extra_dirs='

+     %{_prefix}/lib/koji-builder-plugins

+     %{_prefix}/koji-hub-plugins

+     %{_datadir}/koji-hub

+     %{_datadir}/koji-web/lib/kojiweb

+     %{_datadir}/koji-web/scripts'

+ %if 0%{py2_support} > 1

+ for fn in $extra_dirs ; do

+     %py_byte_compile %{__python2} %{buildroot}$fn

+ done

+ %endif

+ %if 0%{py3_support} > 1

+ for fn in $extra_dirs ; do

+     %py_byte_compile %{__python3} %{buildroot}$fn

+ done

+ %endif

  %endif

  

  %clean
@@ -394,20 +488,20 @@ 

  %dir /etc/koji.conf.d

  %doc docs Authors COPYING LGPL

  

- %if 0%{with_python2}

+ %if 0%{py2_support}

  %files -n python2-%{name}

  %defattr(-,root,root)

  %{python2_sitelib}/%{name}

  %{python2_sitelib}/koji_cli

  %endif

  

- %if 0%{with python3}

+ %if 0%{py3_support}

  %files -n python%{python3_pkgversion}-koji

  %{python3_sitelib}/%{name}

  %{python3_sitelib}/koji_cli

  %endif

  

- %if 0%{with_python2}

+ %if 0%{py2_support}

  %files -n python2-%{name}-cli-plugins

  %defattr(-,root,root)

  %{python2_sitelib}/koji_cli_plugins
@@ -416,7 +510,7 @@ 

  #%%config(noreplace) %%{_sysconfdir}/koji/plugins/*.conf

  %endif

  

- %if 0%{with python3}

+ %if 0%{py3_support}

  %files -n python%{python3_pkgversion}-%{name}-cli-plugins

  %defattr(-,root,root)

  %{python3_sitelib}/koji_cli_plugins
@@ -432,13 +526,13 @@ 

  %config(noreplace) /etc/koji-hub/hub.conf

  %dir /etc/koji-hub/hub.conf.d

  

- %if 0%{with_python2}

+ %if 0%{py2_support} > 1

  %files -n python2-%{name}-hub

  %defattr(-,root,root)

  %{_datadir}/koji-hub/*.py*

  %endif

  

- %if 0%{with python3}

+ %if 0%{py3_support} > 1

  %files -n python%{python3_pkgversion}-%{name}-hub

  %defattr(-,root,root)

  %{_datadir}/koji-hub/*.py
@@ -449,29 +543,29 @@ 

  %dir /etc/koji-hub/plugins

  %config(noreplace) /etc/koji-hub/plugins/*.conf

  

- %if 0%{with_python2}

+ %if 0%{py2_support} > 1

  %files -n python2-%{name}-hub-plugins

  %defattr(-,root,root)

  %{_prefix}/lib/koji-hub-plugins/*.py*

  %endif

  

- %if 0%{with python3}

+ %if 0%{py3_support} > 1

  %files -n python%{python3_pkgversion}-%{name}-hub-plugins

  %defattr(-,root,root)

  %{_prefix}/lib/koji-hub-plugins/*.py

  %{_prefix}/lib/koji-hub-plugins/__pycache__

  %endif

  

- %if 0%{with_python2}

  %files builder-plugins

  %defattr(-,root,root)

  %dir /etc/kojid/plugins

  %config(noreplace) /etc/kojid/plugins/*.conf

  %dir %{_prefix}/lib/koji-builder-plugins

  %{_prefix}/lib/koji-builder-plugins/*.py*

+ %if 0%{py3_support} > 1

+ %{_prefix}/lib/koji-builder-plugins/__pycache__

  %endif

  

- %if 0%{with_python2}

  %files utils

  %defattr(-,root,root)

  %{_sbindir}/kojira
@@ -489,29 +583,26 @@ 

  %{_sbindir}/koji-shadow

  %dir /etc/koji-shadow

  %config(noreplace) /etc/koji-shadow/koji-shadow.conf

- %endif

  

- %if 0%{with_python2}

- %files -n python2-%{name}-web

+ %files web

  %defattr(-,root,root)

- %{_datadir}/koji-web

  %dir /etc/kojiweb

  %config(noreplace) /etc/kojiweb/web.conf

  %config(noreplace) /etc/httpd/conf.d/kojiweb.conf

  %dir /etc/kojiweb/web.conf.d

+ 

+ %if 0%{py2_support} > 1

+ %files -n python2-%{name}-web

+ %defattr(-,root,root)

+ %{_datadir}/koji-web

  %endif

  

- %if 0%{with python3}

+ %if 0%{py3_support} > 1

  %files -n python%{python3_pkgversion}-%{name}-web

  %defattr(-,root,root)

  %{_datadir}/koji-web

- %dir /etc/kojiweb

- %config(noreplace) /etc/kojiweb/web.conf

- %config(noreplace) /etc/httpd/conf.d/kojiweb.conf

- %dir /etc/kojiweb/web.conf.d

  %endif

  

- %if 0%{with_python2}

  %files builder

  %defattr(-,root,root)

  %{_sbindir}/kojid
@@ -552,9 +643,7 @@ 

    /sbin/chkconfig --del kojid

  fi

  %endif

- %endif

  

- %if 0%{with_python2}

  %files vm

  %defattr(-,root,root)

  %{_sbindir}/kojivmd
@@ -590,7 +679,6 @@ 

    /sbin/service kojivmd stop &> /dev/null

    /sbin/chkconfig --del kojivmd

  fi

- %endif

  

  %if %{use_systemd}

  

file modified
+14 -13
@@ -29,23 +29,24 @@ 

  		echo "ERROR: A destdir is required"; \

  		exit 1; \

  	fi

- 	mkdir -p $(DESTDIR)/$(HUBPLUGINDIR); \

- 	install -p -m 644 $(HUBFILES) $(DESTDIR)/$(HUBPLUGINDIR); \

- 	$(PYTHON) -c "import compileall; compileall.compile_dir('$(DESTDIR)/$(HUBPLUGINDIR)', 1, '$(HUBPLUGINDIR)', 1)"; \

- 	mkdir -p $(DESTDIR)/$(HUBCONFDIR); \

- 	install -p -m 644 $(HUBCONFFILES) $(DESTDIR)/$(HUBCONFDIR); \

- 	if [ "$(PYMAJORVER)" == "2" ] ; then \

- 		mkdir -p $(DESTDIR)/$(BUILDERPLUGINDIR); \

- 		install -p -m 644 $(BUILDERFILES) $(DESTDIR)/$(BUILDERPLUGINDIR); \

- 		$(PYTHON) -c "import compileall; compileall.compile_dir('$(DESTDIR)/$(BUILDERPLUGINDIR)', 1, '$(BUILDERPLUGINDIR)', 1)"; \

- 		mkdir -p $(DESTDIR)/$(BUILDERCONFDIR); \

- 		install -p -m 644 $(BUILDERCONFFILES) $(DESTDIR)/$(BUILDERCONFDIR); \

- 	fi

+ 

+         ifndef KOJI_MINIMAL

+ 		mkdir -p $(DESTDIR)/$(HUBPLUGINDIR);

+ 		install -p -m 644 $(HUBFILES) $(DESTDIR)/$(HUBPLUGINDIR);

+ 		$(PYTHON) -c "import compileall; compileall.compile_dir('$(DESTDIR)/$(HUBPLUGINDIR)', 1, '$(HUBPLUGINDIR)', 1)";

+ 		mkdir -p $(DESTDIR)/$(HUBCONFDIR);

+ 		install -p -m 644 $(HUBCONFFILES) $(DESTDIR)/$(HUBCONFDIR);

+ 		mkdir -p $(DESTDIR)/$(BUILDERPLUGINDIR);

+ 		install -p -m 644 $(BUILDERFILES) $(DESTDIR)/$(BUILDERPLUGINDIR);

+ 		$(PYTHON) -c "import compileall; compileall.compile_dir('$(DESTDIR)/$(BUILDERPLUGINDIR)', 1, '$(BUILDERPLUGINDIR)', 1)";

+ 		mkdir -p $(DESTDIR)/$(BUILDERCONFDIR);

+ 		install -p -m 644 $(BUILDERCONFFILES) $(DESTDIR)/$(BUILDERCONFDIR);

+         endif

  

  	mkdir -p $(DESTDIR)/$(CLIPLUGINDIR)

  	install -p -m 644 $(CLIFILES) $(DESTDIR)/$(CLIPLUGINDIR)

  	$(PYTHON) -c "import compileall; compileall.compile_dir('$(DESTDIR)/$(CLIPLUGINDIR)', 1, '$(CLIPLUGINDIR)', 1)"

  	mkdir -p $(DESTDIR)/$(CLICONFDIR)

          ifneq "$(CLICONFFILES)" ""

- 	install -p -m 644 $(CLICONFFILES) $(DESTDIR)/$(CLICONFDIR)

+ 		install -p -m 644 $(CLICONFFILES) $(DESTDIR)/$(CLICONFDIR)

          endif

This is a follow up to the three py3 PRs merged earlier -- #1117, #891, and #921. This may need further adjustment. Feedback welcome.

This is an attempt to streamline the various py2/3 support cases we need to cover. Some targets are p2 only, others py3 only, and other both to different degrees.

sed -e "s|#!/usr/bin/python2|#!/usr/bin/python3|" $RPM_BUILD_ROOT/usr/bin/koji is more readable...

@mikem The koji-utils and koji-vm content looks like they have Python 3 adaptations, so why can't they build for Python 3?

This will not work, since it's generated by brp-python-bytecompile later...

Btw, broken case I've hit was py2=1, py3=2 on F29. In such cases hub files were bytcompiled for py2 even if they were not packaged.

The koji-utils and koji-vm content looks like they have Python 3 adaptations, so why can't they build for Python 3?

Ah, it appears you are correct. I'd been focused on the three recent ones (hub, web, builder), and I'd simply forgotten that PR #685 included py3 work for utils. I don't know how thorough that work was though. A casual run of kojira with python3 seems to work. I'll adjust that then. Thanks

Btw, broken case I've hit was py2=1, py3=2 on F29. In such cases hub files were bytcompiled for py2 even if they were not packaged.

yep, this is because on F29 the __python macro is still pointed at python2. Our settings remain p2=2,p3=1 on f29, which works, and p2=1,p3=2 works for F30 at least in my testing.

I guess I might need to do something about the auto-byte-compiling, but I'm not sure the best way yet, particularly with the approach being quite different across recent Fedoras

https://fedoraproject.org/wiki/Packaging:Python_Appendix#Manual_byte_compilation

sed -e "s|#!/usr/bin/python2|#!/usr/bin/python3|" $RPM_BUILD_ROOT/usr/bin/koji is more readable...

good call

https://pagure.io/fork/tkopecek/koji/commits/py23macros-tkopecek

I have a few concerns with simply turning off _python_bytecompile_extra

  1. this is theoretically f29+ only
  2. we've been building with it on so far, we might be dropping some compiled files

I would just go ahead and say just always do byte compilation to keep it consistent with EL and older Fedoras. I do this with Pagure and MirrorManager2 in EPEL and Fedora.

I would just go ahead and say just always do byte compilation to keep it consistent with EL and older Fedoras. I do this with Pagure and MirrorManager2 in EPEL and Fedora.

The trick here are the .py files we have outside of python[23]_sitelib. These extra files are auto compiled with %{__python} (only) which is often not quite the right thing. The Fedora guidelines suggest disabling auto compilation and triggering it manually, but the details vary across Fedora versions.

Granted, Koji's Makefiles do their own byte compilation. We've had that in place since before the magic macros I think. However, auto compilation does things a little differently (e.g. it also generates .pyo files, while the Makefiles just generate .pyc files).

5 new commits added

  • manually trigger extra byte compilation
  • handle byte-compiling for fedora
  • remove qpid requires
  • vm and utils subpackages for py3 too
  • more readable sed expression
5 years ago

rebased onto 712b5af

5 years ago

1 new commit added

  • keep config in koji-web package
5 years ago

Metadata Update from @jcupova:
- Pull-request tagged with: testing-ready

5 years ago

+1 for koji 1.17

I'm not sure if we shouldn't switch from Makefile to setuptools later (as there is already setup.py for PyPi upload). It is de facto standard these days and automatic macros probably would behave more transparent with such input.

btw. .pyc generated by make are overwritten by autocompilation on Fedora anyway.

Metadata Update from @jcupova:
- Pull-request untagged with: testing-ready

5 years ago

I'm not sure if we shouldn't switch from Makefile to setuptools later

Agreed, though I think we'll want to rearrange a number of things to do that effectively. I'd be interested in pursuing that for 1.18

I think this is good to go as-is. We can look at replacing the Makefile with setuptools in 1.18, and when we do that, we can have a larger conversation about how Koji should be structured for that.

Commit dc7b367 fixes this pull-request

Pull-Request has been merged by mikem

5 years ago