pck-update: stricter checks on buildreqs with explicit arch

This commit is contained in:
Silvan Calarco 2015-04-16 00:34:36 +02:00
parent 68ad87406c
commit 2fa427ff26

View File

@ -1991,12 +1991,12 @@ build requirement found"": \`${NOTE}$f${NORM}' ""\
# remove duplicates # remove duplicates
buildreqs_to_install=( buildreqs_to_install=(
$(for f in ${buildreqs_to_install[@]}; do $(for f in ${buildreqs_to_install[@]}; do
if [ "${f/.*}" != "${f}" ]; then if [ "${f/*.}" == "arm" -o "${f/*.}" == "x86_64" -o "${f/*.}" == "i586" ]; then
# if arch specified convert e.g. package.i586 to package@i586 # if arch specified convert e.g. package.i586 to package@i586
echo ${f/./@} echo ${f/./@}
elif [ "${BUILD_ARCH}" == "x86_64" ]; then elif [ "${BUILD_ARCH}" == "x86_64" -a "${target_cpu}" != "x86_64" ]; then
# x86_64: specifying arch is necessary (FIXME: problems with .noarch) # x86_64: specifying arch is necessary (FIXME: problems with .noarch)
echo $f@$target_cpu echo $f@${target_cpu}
else else
# classic behaviour # classic behaviour
echo $f echo $f