Skip to content

Support for installing in Fedora - #1945

Open
ricferpas wants to merge 8 commits into
openhwfoundation:mainfrom
ricferpas:fedora
Open

ricferpas wants to merge 8 commits into
openhwfoundation:mainfrom
ricferpas:fedora

Conversation

@ricferpas

Copy link
Copy Markdown

This PR adds support for installing in Fedora in addition to the already supported distributions (Ubuntu, Debian, SUSE and Red Hat). Only minimal changes are required.

@davidharrishmc

Copy link
Copy Markdown
Contributor

Thanks for the PR.  You’ll need to sign an Eclipse Contributor Agreement indicating that you are licensing your contributions as open source.

You need to create an account with https://www.eclipse.org/

Sign the agreement, https://www.eclipse.org/legal/ECA.php

@davidharrishmc

Copy link
Copy Markdown
Contributor

Suggested changes:

  1. Nothing tests the new branch. .github/workflows/install.yml has no Fedora entry. A fedora:44 container job should be added. CI hasn't run on this PR at all apart from the ECA check.
  2. The README's supported-distro list (README.md:86) doesn't mention Fedora.
  3. The wget gate keys on the distro name ("$ID" != fedora), not on capability. Testing whether wget supports --retry-on-host-error would cover RHEL 8, Fedora and Fedora derivatives at once. The rewritten condition also uses the obsolescent [ … -a … ], where the rest of the script uses [[ … && … ]] or (( )).
  4. Fedora 43 is rejected outright (< 44 exits). Fedora 43 is still supported upstream until around December 2026. A warning, as the script gives for newer versions, would be friendlier. That's a policy call.

Comment thread bin/wally-environment-check.sh Outdated
Comment thread bin/wally-package-install.sh Outdated
Comment on lines +52 to +56
if [[ "$FAMILY" = "fedora" ]] ; then
PYTHON_OPTION="--without-python" # Avoid problems when the python version is incorrect
else
PYTHON_OPTION=""
fi

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What error is this causing? I'd rather fix the Python version instead of telling it to build without Python.

@ricferpas

Copy link
Copy Markdown
Author

The error from the log is as follows:

gcc.compile.c++ bin.v2/libs/python/build/gcc-16/release/x86_64/python-3.14/threading-multi/visibility-hidden/list.o
In file included from ./boost/python/detail/prefix.hpp:13,
                 from ./boost/python/list.hpp:8,
                 from /opt/riscv/boost_1_90_0/libs/python/src/list.cpp:5:
./boost/python/detail/wrap_python.hpp:57:11: fatal error: pyconfig.h: No such file or directory
   57 | # include <pyconfig.h>
      |           ^~~~~~~~~~~~
compilation terminated.

Note that despite not finding pyconfig.h, python is detected earlier in the process, with version 3.14 in /usr.

My first idea was to fix it properly, possibly installing the correct Python version in the docker image or using a virtual env. However, I examined the output from another build configuration (e.g., OpenSuse) and I noticed that Python was not being detected there at all, hence I concluded that it is not really necessary to build the python support in boost. Since fixing this problem can be time consuming and there is no actual benefit, I chose the workaround.

If you think that this is not acceptable, I will try another way. But currently I think that disabling python support in boost is the best way to proceed.

@ricferpas

Copy link
Copy Markdown
Author

I have checked and all other distros build boos without Python support, emitting the following warning:

warning: No python installation configured and autoconfiguration note: failed. See http://www.boost.org/libs/python/doc/building.html note: for configuration instructions or pass --without-python to note: suppress this message and silently skip all Boost.Python targets

In the case of Fedora, it detects Python 3.14 and then tries to build Python support, but fails.

Maybe the right fix to keep the build as it is for all distros is to add --without-python unconditionally?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants