Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: do not systematically build python spk when building python dependent modules #6197

Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 14 additions & 12 deletions .github/actions/prepare.sh
Original file line number Diff line number Diff line change
Expand Up @@ -74,18 +74,20 @@ done

# for python (310, 311) find all packages that depend on them
for py in python310 python311; do
python_dependent_packages=$(find spk/ -maxdepth 2 -mindepth 2 -name "Makefile" -exec grep -Ho "PYTHON_PACKAGE = ${py}" {} \; | grep -Po ".*spk/\K[^/]*" | sort | tr '\n' ' ')

# If packages contain a package that depends on python (or is python), then ensure
# relevant python spk is first in list
for package in ${packages}
do
if [ "$(echo ${py} ${python_dependent_packages} | grep -ow ${package})" != "" ]; then
packages_without_python=$(echo "${packages}" | tr ' ' '\n' | grep -v "${py}" | tr '\n' ' ')
packages="${py} ${packages_without_python}"
break
fi
done
if [ "$(echo ${packages} | grep -ow ${py})" != "" ]; then
python_dependent_packages=$(find spk/ -maxdepth 2 -mindepth 2 -name "Makefile" -exec grep -Ho "PYTHON_PACKAGE = ${py}" {} \; | grep -Po ".*spk/\K[^/]*" | sort | tr '\n' ' ')

# If packages contain a package that depends on python (or is python), then ensure
# relevant python spk is first in list
for package in ${packages}
do
if [ "$(echo ${py} ${python_dependent_packages} | grep -ow ${package})" != "" ]; then
packages_without_python=$(echo "${packages}" | tr ' ' '\n' | grep -v "${py}" | tr '\n' ' ')
packages="${py} ${packages_without_python}"
break
fi
done
fi
done

# find all noarch packages
Expand Down