Introduce a bunch of helper functions to split out the finding of a
specific python interpreter, a specific python dependency within a
given python interpreter, and the handling of dependencies for each of
the possible SBOM operations: GENERATE_JSON, VERIFY_SBOM, and
RUN_NTIA.
In a future change this will allow us to conditionally enable certain
operations, depending on which dependencies are available, without
failing the build outright.
One behavior change is better logging of what goes wrong if a
dependency is missing.
Another is the double look up of python on macOS, to account for the
system framework python not having the required dependencies.
These was previously an internal opt in, but now it is done
automatically.
Task-number: QTBUG-122899
Change-Id: I3054f2649c0092dc5f2d3e299065f0f62dc6c5fb
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
(cherry picked from commit 29a435faf84fbe9a80a3054c2dcce4d691b46e20)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>