OSInside / kiwi

KIWI - Appliance Builder Next Generation
https://osinside.github.io/kiwi
GNU General Public License v3.0
300 stars 152 forks source link

Fixed spec file for TW build #2581

Closed schaefi closed 3 months ago

schaefi commented 3 months ago

On openSUSE Factory/TW the python packages are versioned and should be named according to the python interpreter

Conan-Kudo commented 3 months ago

This should not be required. The default python flavor should always have a python3- Provides.

Conan-Kudo commented 3 months ago

If you do this, then kiwi will continually break when python versions are swapped out.

schaefi commented 3 months ago

This should not be required. The default python flavor should always have a python3- Provides.

Yes you are right. So I added a Provides tag such that we always have python3-kiwi either as a direct package or through a provides tag. You may ask why. The reason is for suse many python packages uses the suse provided macros to make dealing with python and dependencies easier. There is one that does for example `%{python_module Sphinx} and it resolves to python311-Sphinx or whatever python default version the provided distro has. Thus when we built kiwi for TW and also for Leap/SLES it should be able to resolve both, versioned and non-versioned names.

I have submitted this spec change to :Staging to see if it causes issues on the integration tests, but it seems to work

Thoughts ?

Conan-Kudo commented 3 months ago

What problem are we trying to solve here? Because for Tumbleweed and Leap 16, we absolutely want to always use the default version, and for Leap 15, we need to override to use a non-default version of Python.

schaefi commented 3 months ago

I tried to explain the problem. There is a package and it has this Requires

Requires:    %{python_module kiwi}

That doesn't work for TW because the above macro resolves to python311-kiwi which does not exist because at the moment our package is named python3-kiwi.

I know that this change here will make the TW kiwi build to stick with py311 and will not automatically follow new default interpreters, but would that hurt ? they will not drop 311 from TW

I'm open for anything that solves this mess

Conan-Kudo commented 3 months ago

So then the simple fix is to add pythonXY-kiwi = %{version}-%{release} provides rather than what this is. Let me come up with something, give me a tick.

schaefi commented 3 months ago

So then the simple fix is to add pythonXY-kiwi = %{version}-%{release} provides rather than what this is. Let me come up with something, give me a tick.

ok yes sounds better. Thanks for helping