Skip to content

Commit bf95480

Browse files
authored
Avoid downloading dependencies for broken pacjages (SynoCommunity#7009)
* github-action: Fix removal of broken packages part of prepare.sh
1 parent 3f2e104 commit bf95480

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

.github/actions/prepare.sh

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,18 @@ fi
4848
# remove duplicate packages
4949
packages=$(printf %s "${SPK_TO_BUILD}" | tr ' ' '\n' | sort -u | tr '\n' ' ')
5050

51+
# Remove BROKEN packages (not present in dependency list)
52+
filtered_packages=
53+
for package in ${packages}
54+
do
55+
if grep -q "^${package}:" "${DEPENDENCY_LIST}"; then
56+
filtered_packages+="${package} "
57+
else
58+
echo "===> Skipping BROKEN or invalid package: ${package}"
59+
fi
60+
done
61+
packages=$(echo "${filtered_packages}" | xargs)
62+
5163
# for ffmpeg v5-7 find all packages that depend on them
5264
for i in {5..7}; do
5365
ffmpeg_dependent_packages=$(find spk/ -maxdepth 2 -mindepth 2 -name "Makefile" -exec grep -Ho "FFMPEG_PACKAGE = ffmpeg${i}" {} \; | grep -Po ".*spk/\K[^/]*" | sort | tr '\n' ' ')

0 commit comments

Comments
 (0)